cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
pNabin
Level 8

Getting current apps GUID ID within the app

Is it possible to get current PowerApps application GUID/ID within the PowerApps?

I need to send the email with the link to this app, and static value works but when migrating into another environment, we need to change manually in multiple places. So, getting the app id dynamically would be perfect.

 

Thanks,

Nabin

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Getting current apps GUID ID within the app

@pNabin 

Yes.  The way I go about it, you need the PowerAppsforAdmins connector to do it.  

Then, to test, throw in a label and set the Text property to:

LookUp(PowerAppsforAdmins.GetAdminApps(
     LookUp(PowerplatformforAdmins.GetAdminEnvironment().value, properties.creationType="DefaultTenant").name
     ).value, properties.displayName="yourAppName").name

This, of course, assumes the DefaultTenant environment, but you can adjust as needed.

End result in your test label...the GUID of the app you are looking for.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

4 REPLIES 4
Super User
Super User

Re: Getting current apps GUID ID within the app

@pNabin 

Yes.  The way I go about it, you need the PowerAppsforAdmins connector to do it.  

Then, to test, throw in a label and set the Text property to:

LookUp(PowerAppsforAdmins.GetAdminApps(
     LookUp(PowerplatformforAdmins.GetAdminEnvironment().value, properties.creationType="DefaultTenant").name
     ).value, properties.displayName="yourAppName").name

This, of course, assumes the DefaultTenant environment, but you can adjust as needed.

End result in your test label...the GUID of the app you are looking for.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.

View solution in original post

pNabin
Level 8

Re: Getting current apps GUID ID within the app

Thank you @RandyHayes
Isn't there anyway without using the admin connector? 

Super User
Super User

Re: Getting current apps GUID ID within the app

@pNabin 

Hmmm, none that I am aware of.  But, I haven't researched much on it.  Perhaps others might chime in on it.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Super User
Super User

Re: Getting current apps GUID ID within the app

I am not aware of a better option for getting the App Id than what @RandyHayes suggest. however, you may be able to simplify the updating process when moving the app by creating a global variable in the OnStart property and manually set the App Id. Then where ever you use the App Id in your app would use the global variable. When you move the app to a new environment then you would just need to update the global variable in the OnStart and you are done.



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (5,292)