PowerApps Canvas Apps: How to display the version number inside the app

The PowerApps for Apps Maker connector is awesome. One of the actions it can call is ‘Get Versions’. In this video I show how you can use the action to display the version number inside the app.

The TL;DW quick explanation is with the PowerApps for App Makers connection added to your Canvas App run this function:

ClearCollect(myAppVersionsv2,PowerAppsforAppMakers.GetAppVersions("App ID"))

App ID is the unique identifier for you app.

After running that function you will be able to add some text which would look something like this depending on your preference of style:

"<b>Version </b>"&CountIf(Ungroup(myAppVersionsv2,"value"),properties.lifeCycleId="Published" Or properties.appVersion<=publishedVersionv2)

Please let me know what you think! If you would like a copy of the .msapp file please get in touch and I will pass it on.

I’ve posted a idea on the PowerApps Ideas Forum that would help speed up this process. If you agree please up vote it here.

Comments

  1. Dion Mills

    This doesn’t work for me I’m afraid, i have deleted some versions in the past so counting the versions gives me a lower number than my published version for example i have version 1, 2, 5, 6, 9. Using this gives me a version number of 5 as i have 5 versions, shame.

    1. Post
      Author
      Lachlan Wright

      Hi Dion,

      That is a shame. Why do you delete versions? I’d recommend against deleting them. I can’t seem to find any limit to the number or cost associated with storage so even if the version isn’t needed I can’t see a reason to get rid of it. You could hard code into the app the number of deleted versions and add it to the count so it works for future versions.

      Cheers,

      Lachlan

Leave a Reply

Your email address will not be published. Required fields are marked *