Android Question Controlling #VersionName: in B4A

Kiumbe

Member
Licensed User
Hello,
I want to auto increment version name of the app for easier tracking and maintenance, I came across this Tutorial that has guided me very well to achieve my goal, however, when I read the value of the version from the compiletime.txt file and store the version in a string variable and try to assign the VersionName the new number, the app displays the variable name itself. I do this to assign new version number to the #VersionName:
Assign VersionName a variable:
Dim strVersionCode As String
#VersionName: Sys- strVersionCode

the Output on my app is Sys- strVersionCode instead of for example Sys- 2.0
Where am I going wrong on this?
As I cannot also assign the #VersionCode: an int variable, how do I update the #VersionCode: of my app to reflect progressive updates of my app?

Thank you Members.
 

Kiumbe

Member
Licensed User
This cannot work. #VersionName is handled by the compiler and its value is used while the compiler generated AndroidManifest.xml.
Thanks Erel for your response, so it means I have to type the #VersionCode and #VersionName manually on the #Region every time I create a new update of my app? such as below:
Updating app New Version:
#Region  Project Attributes
    #VersionCode: 1
    #VersionName: Sys-1.0
#End Region

Is this correct?

Thanks again.
 
Upvote 0
Top