cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
staceylaney
Advocate I
Advocate I

Get User Profile (V2) to get email address and send email not working

I am using an InfoPath form with People/Group Picker fields for approvers, published to a SharePoint form library.  When publishing the form, people/group picker fields must be configured to SP site columns as either "DisplayName", "AccountID" or "AccountType".

 

The Flow should simply pull the email address of the user in the people picker field to send an email.  Here is how the Flow is configured (simple test flow):

 

Annotation 2019-10-11 161130a.png

 

This is the error I get if people picker configured as "DisplayName":

Annotation 2019-10-11 161130.png

 

This is the error I get if people picker configured as "AccountID":

Annotation 2019-10-11 161130b.png

 

This is the error I get if people picker configured as "AccountType":

Annotation 2019-10-11 161130c.png

 

 

Typically people picker fields are published as "DisplayName" and they are recognized as people picker fields in SharePoint and seemingly even in Flow, but as you can see, Flow is having a hard time pulling AD/Azure user info correctly and I'm not sure if it's because of InfoPath or the way we have users setup in AD/Azure, or maybe I'm just not configuring the Flow correctly. 

 

Any help or guidance would be appreciated.

 

1 ACCEPTED SOLUTION

Accepted Solutions
Gristy
Resident Rockstar
Resident Rockstar

Hello

 

Use account id but you need to remove the claims portion first. use the following in a compose action:

 

replace(YOURACCOUNTIDVARHERE,'i:0#.f|membership|','')

 

Replace YOURACCOUNTIDVARHERE with your Account ID variable and use the output in the office 365 profile lookup action

View solution in original post

3 REPLIES 3
abm
Super User III
Super User III

Hi @staceylaney 

 

For Get user profile(v2) you need to pass the User principal name or email id. I can see your trigger is 'When a new item is created' Try to use the 'Created by Email' mapping under Get user profile. 

 

Let me know whether it works or not.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials
Gristy
Resident Rockstar
Resident Rockstar

Hello

 

Use account id but you need to remove the claims portion first. use the following in a compose action:

 

replace(YOURACCOUNTIDVARHERE,'i:0#.f|membership|','')

 

Replace YOURACCOUNTIDVARHERE with your Account ID variable and use the output in the office 365 profile lookup action

View solution in original post

@Gristy- this worked BEAUTIFULLY!  THANKS!!!

Helpful resources

Announcements
MPA 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

MSFTBizAppsLaunchEvent

Experience what’s next for Power Virtual Agents

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Top Solution Authors
Top Kudoed Authors
Users online (44,039)