This thread was migrated from an old forum. It may contain information that are no longer valid. For further assistance, please post a new question or open a support ticket from the Customer Support portal. |
This thread was migrated from an old forum. It may contain information that are no longer valid. For further assistance, please post a new question or open a support ticket from the Customer Support portal. |
@Rakesh Khandagale
You can get the app version using appConfig. For more details, refer the below basecamp pot.
https://basecamp.kony.com/s/question/0D56A00000HvTuhSAF/control-of-my-app-version-in-production
Thanks for the quick reply. Using "appConfig" can we also get build version as well?
@Rakesh Khandagale
appConfig will provide below info of the app.
{"appId":"Sample","appName":"Sample","appVersion":"1.0.0","isDebug":true,"isMFApp":false,"eventTypes":["FormEntry","Error","Crash"]}
@Rakesh Khandagale ,
If by build version, you mean Visualizer version, then the answer is no. You cannot get visualizer version in the app at runtime because Visualizer version is not relevant for the app version.
And as @Twvcey Rvndvll confirmed, app version can be read from appConfig global object at runtime.
@Rakesh Khandagale
To get the Build Version/Bundle Version you can use the below NFI.
First import the Foundation framework use the below code
var NSBundle=objc.import("NSBundle");
var version=NSBundle.mainBundle.infoDict
kony.print(JSON.stringify(version))
From Version read the CFBundleVersion which will give you the Build version. This approach might increase the application size. Instead of this you can raise a new Idea(feature request) in the Ideation Portal to get a direct API to read the request info from the application.
Is there an Android equivalent that you can recommend?
Yeah is there an android way to do it?