web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Automatic email with p...
Power Apps
Unanswered

Automatic email with people field

(1) ShareShare
ReportReport
Posted on by 44

Hi guys

 

@mdevaney  @v-siky-msft  @iAm_ManCat  @yashag2255  @timl @RandyHayes 

 

I have a record of the industry team where it picks up the Sharepoint's People field, because of that I have access to people's email information.
To reduce errors and time in registration, how to do when the person chooses his name in combobox "Collaborator" do so email appears in the Email field and could use the SubmitForm (EditForm1) command in IconAccept1.

 

1.PNG

 

2.png

 

3.png

 

Categories:
I have the same question (0)
  • Verified answer
    mdevaney Profile Picture
    29,989 Moderator on at

    @hiranfilho 

    If the source your "collaborator" combobox is a SharePoint person column I think you can just reference the "mail" property.

     

    Put this code in the Default value of your Email textbox.  I assume email is a Text data type.

    DataCardValue18.Selected.mail

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

  • poweractivate Profile Picture
    11,078 Most Valuable Professional on at

    @hiranfilho 

     

    You can try to send the name to Flow then search for user, get first value, then get Email address and return it to PowerApps.

     

    If you want this done quickly from Power Automate (Formerly Microsoft Flow) there is a convenient Flow Action for this called "Office 365 - Search for users" - you can find it by typing Office 365 or Search for users when looking for Flow actions after clicking "New Step". 

     

    SearchForUsers.png

     

     

    You would feed the PowerApps input here instead of "John" - yes it will search the name, and a variety of other pieces automatically.

     

    Note, this returns multiple values. After you get the user, if you want only the first user, get the first user using a Compose action. 

    Some people use an Apply To Each even if there's only one - we prefer to get the first directly. However it requires you to know exactly how to do this. Use this example - new Compose Action after the aformentioned action, with something like:  

     

    body('Search_for_users')?[0]

     

     in this case.

     

    Or, if you do need to email a potential match of multiple users, even better - then use an apply to each.

    In your case though, you may only need one user, so the first match would work.

     

     

    Even if you limit the number of returned results to one, the type returned is an Array, so either an Apply to Each should be used, or our preferred way

     

    body('Search_for_users')?[0] 

     

    to get only the first value in cases where it is known only the first value is desired.

  • poweractivate Profile Picture
    11,078 Most Valuable Professional on at

    @hiranfilho 

     

    Or if it is directly accessible to you in PowerApps as a property in your case like @mdevaney  said, then you should prefer that way instead.

  • hiranfilho Profile Picture
    44 on at

    Hi @mdevaney ,

     

    Correct, putting in the Default field, but the formula is:

     

    Spoiler (Highlight to read)
    Concat (DataCardValue18.SelectedItems; Email)
    Concat (DataCardValue18.SelectedItems; Email)

     

    The other formula didn't work

  • rebeccas Profile Picture
    2,591 on at

    If it is a combo box that you want to default to the current user and you want that information stored (SharePoint specifically) you need to use:

     

    Default (or update of card)

    {DisplayName:User().FullName,

    Claims: "i:0#.f|membership|" & Lower(User().Email),

    Department:"",
    Email:User().Email,
    JobTitle:"",
    Picture:""}

     

    Otherwise it will just display the current users name or email but not actually store it to the data source.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard