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

Community site session details

Session Id : is6snqTPJpba2GyY8krnEE
Power Apps - Building Power Apps
Answered

Split a concatenated email string to Office365 DisplayName

Like (0) ShareShare
ReportReport
Posted on 16 May 2023 02:00:31 by 504

Hello guys,

I have a concatenated email string and want to split it to Office 365 as a text label inside a gallery.

 

Input: ( ; as delimiter)
MorganFreeman@gmail.com;JonSnow@gmail.com

 

Output (Text Label inside gallery) 

Morgan Freeman

Jon Snow

 

I am using this code however it does not work I think it needs to split first before going inside the office365 function

 

Substitute(Concat(Office365Users.SearchUser({searchTerm:ThisItem.'ADN Name'}).DisplayName,DisplayName,";"),";",Char(13))

The ThisItem.'ADN Name' is a single line of text which holds my input from SharePoint.

 

I'm trying to this for 3 days already, any help will be much appreciated.

 

  • nagestiada Profile Picture
    504 on 16 May 2023 at 07:18:02
    Re: Split a concatenated email string to Office365 DisplayName

    @WarrenBelz Thank you very much! now it works!

  • Verified answer
    WarrenBelz Profile Picture
    148,894 Most Valuable Professional on 16 May 2023 at 06:32:26
    Re: Split a concatenated email string to Office365 DisplayName

    @nagestiada ,

    Try this instead

    Concat(
     ForAll(
     Split(
     ThisItem.'ADN Name',
     ";"
     ) As aMails,
     First(Office365Users.SearchUser({searchTerm: aMails.Value})).DisplayName
     ),
     Value,
     Char(10)
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

  • nagestiada Profile Picture
    504 on 16 May 2023 at 04:02:03
    Re: Split a concatenated email string to Office365 DisplayName

    Hello @WarrenBelz, appreciate your help! There is no error with your code. however, there's also no output. The emails shows when I try to output only ThisItem.'ADN Name' directly to the text label.

  • WarrenBelz Profile Picture
    148,894 Most Valuable Professional on 16 May 2023 at 02:32:07
    Re: Split a concatenated email string to Office365 DisplayName

    Hi @nagestiada ,

    This should in theory work

    Concat(
     ForAll(
     Split(
     ThisItem.'ADN Name',
     ";"
     ) As aMails,
     First(Office365Users.SearchUserV2({SearchTerm: aMails.Value}).value).DisplayName
     ),
     Value,
     Char(10)
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 791 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 410 Super User 2025 Season 2

#3
mmbr1606 Profile Picture

mmbr1606 275 Super User 2025 Season 2

Loading complete