Have script that pulls version into a constant. Updated version in XOJO (2022 release1) but when I build the app it still has the old version. Xojo shows the new version. Any hints?
Could you show us the script?
var v() as string
'v.append " ("
var m as string=join(v,"")
var v1() as string
var m1 as string=join(v1,"")
and screen shots where script is located and version info.
Funny think is it is showing the previous version number when I run in simulator or build.
Uh… in that script, the items that set up the version number are all commented out.
Edit: NM I see that it’s only the last segment.
Print m after the join.
Also, make sure you remove the old one from the device/simulator. I’ve seen cases where they will launch an older version.
It’s like the constant is not getting updated…How is that it is still finding 2.9.6 even though the in xojo shared fields for version shows 2.9.8.
In the window for Xcode transferring the app to phone it has the correct version.
Is there a better way to grab the version?
I had a default value for the constants that’s why they appear to work. If I delete these then the is no copyright or version displayed. So I guess the script is not executing or there is some error.
If I paste script into the IDE New Script menu. And run, it works.
NVM: Script has to be after Build not before. And it works