cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
kcranmer
Frequent Visitor

Using flow to parse EmployeeID for user logged into PowerAPP but email not always passing to Flow

I'm creating a PowerApp that when opened it automatically populates the user name whos logged in by using Office365Users.MyProfileV2().displayname and their employeeID.  I have to parse the EmployeeID (employeeID,department) from JSON via a flow.  To do this I need to populate the Get users profile user field from an email address from the Power App. I created a text entry field in my Power App and I'm using Office365Users.MyProfileV2().mail to get the email address. Then I created the steps PowerApps (V2) Text "Email" and Data Operation Compose Input dynamic value "email" from the previous step.  Problem I'm having is the email address is never captured from the Power App when I run the app from my mobile phone.  It works almost every time when I run the app to test in the browser.  The error I get is "The 'inputs.parameters' of workflow operation 'Get_user_profile_(V2)' of type 'OpenApiConnection' is not valid. Error details: The resolved string values for the following parameters are invalid, they may not be null or empty: 'id'" 

 

kcranmer_0-1656348747840.png

Here is a screen shot of the first 2 steps of the flow.  How can this be setup better to accomplish what I trying to do?  I have tried searching for an answer and have not be able to come up with anything yet. Thanks.

 

kcranmer_1-1656348872393.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
kcranmer
Frequent Visitor

We solved this internally. Instead of using to Office365Users.MyProfileV2().mail, we used OnStart > Set(var_UserEmail, User().email to populate the text input to use in the flow. Apparently the first way is not reliable when using with a flow.

View solution in original post

1 REPLY 1
kcranmer
Frequent Visitor

We solved this internally. Instead of using to Office365Users.MyProfileV2().mail, we used OnStart > Set(var_UserEmail, User().email to populate the text input to use in the flow. Apparently the first way is not reliable when using with a flow.

Helpful resources

Announcements
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Users online (1,512)