Skip to content
Home » User function in Power Apps

User function in Power Apps

The User function in Power Apps is used to retrieve information about the currently logged-in Power Apps users. It provides details such as the user’s full name, email address, Entra object id and profile image.

This function is particularly useful for personalizing the user experience within the app.




Syntax:

User()

The User function returns a record with the following fields:

  • User().FullName: The full name including first and last name of the current user.
  • User().Email: The email address of the current user. It returns the User Principal Name (UPN). A UPN is a username and domain in the format of an email address.
  • User().Image: The URL of the user’s profile picture (if available).
  • User().EntraObjectId: Microsoft Entra Object ID of the current user. This id is useful for calling APIs that use this value. This is a GUID value and unique for each user.

Using User function to get the current user information

Get the current logged-in user’s full name

Add a Text label control and go to OnSelect property of Text lable and write below formula.

User().FullName

It retunrs the full name of the current user, including first and last names.

 

Get the current logged-in user’s email address

Add a Text label control and go to OnSelect property of Text lable and write below formula.

User().Email

It retunrs the email address of the current user.




 

Get the current logged-in user’s profile picture

Add a Image control and go to Image property of  Image control and write below formula.

User().Image

It displays the image of current user.

 

Get the current logged-in user’s Microsoft Entra Object ID

Add a Text label control and go to OnSelect property of Text lable and write below formula.

User().EntraObjectId

It returns the Microsoft Entra Object ID of the current user.

 

 

Also Read..

Loading

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from SQL BI Tutorials

Subscribe now to keep reading and get access to the full archive.

Continue reading