cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ralphtrickey
Helper I
Helper I

Why does user().Email return email in a different format from a list of people?

User.Email returns my network login in the format xy1234@company.org and a Sharepoint List of people has it in the format first.last@company.org.

 

This makes it impossible to check if the current user is part of an  'Admin' list 100%.

 

I'm switching to see if comparing Displayas and Fullname will work.

 

Thanks,

Ralph

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-monli-msft
Community Support
Community Support

Hi @ralphtrickey,

 

The information returned by User() function is for the current PowerApps user. It will match the "Account" information that is displayed in the PowerApps players and studio, which can be found outside of any authored apps. This may not match the current user's information in Office 365 or other services including SharePoint user profiles. For your reference:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-user

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
v-monli-msft
Community Support
Community Support

Hi @ralphtrickey,

 

The information returned by User() function is for the current PowerApps user. It will match the "Account" information that is displayed in the PowerApps players and studio, which can be found outside of any authored apps. This may not match the current user's information in Office 365 or other services including SharePoint user profiles. For your reference:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-user

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Sorry, that wasn't really a question.

 

I understand that there are technical reasons for the emails differing, but to the developer, this is a very clear bug, no matter how you may try to explain why it's happening unless you can suggest a configuration change that would make them align.

 

If Sharepoint and Powerapps were from different companies, I would accept it and move on. That isn't the case here.

 

 

This issue is not solved.  user().email and [metadata type people].email does not return the same value.

In PowerAps it is then impossible to check of filter based on this information.  And except the full name there is no other alternative (no unique ID).

AngryBatVoice
Advocate V
Advocate V

Here's a recent video discussing this issue:

PowerApps User() function & Office 365 Users (2019)

Thank you for this valuable information !

In fact my application was working... execpt for some users...  Those have a blank in their family name that is one time replaced by a . (in email) and another time ignored (login).  So matching was not working for them.

Pstork1
Dual Super User III
Dual Super User III

Its not a bug.  It happens when your AD admins decide to have an email address that doesn't match the user's User Principal Name (UPN). By default AD makes these the same, but some organizations decide they want to differentiate between them.  That is a decision made by your IT staff, not a flaw in the product.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Top Kudoed Authors
Users online (68,500)