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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Extract Phone Number f...
Power Automate
Answered

Extract Phone Number from the body of a meeting invite in Office 365

(0) ShareShare
ReportReport
Posted on by 8
Here are the steps I have taken
 
Here is the output of compose
November 13, 2024 9:30pm EST
Calendar: Woodworking Class / Workshop
Name: Jeff Ginsberg
Phone: (416) 111-2211
Email: jeff@gtawoodworks.com
Location....

These are the functions I have tried to extract JUST the phone number.
Desired Result = (416) 111-2211

Test1
trim(split(split(outputs('Compose'), 'Phone: ')[1], '\n')[0])
Result = 
(416) 111-2211
Email: jeff@gtawoodworks.com
Location...

Test2
trim(first(split(split(outputs('Compose'), 'Phone: ')[1], 'Email:')[0]))
Result =

Test3
trim(first(split(split(outputs('Compose'), 'Phone: ')[1], '\n')))
Result =
(416) 111-2211
Email: jeff@gtawoodworks.com

Test4
trim(first(split(split(outputs('Compose'), 'Phone: ')[1], ' ')))
Result =
(416)

Any help would greatly be appreciated.
 
TIA
Categories:
I have the same question (0)
  • Suggested answer
    Expiscornovus Profile Picture
    33,995 Most Valuable Professional on at
    Try the below expression:
    split(split(outputs('Compose'), 'Phone: ')[1], decodeUriComponent('%0A'))[0]



    Happy to help out 😁

    I share more #PowerAutomate and #SharePointOnline content on my Blog, Bluesky profile or Youtube Channel
  • Verified answer
    Chriddle Profile Picture
    8,721 Super User 2026 Season 2 on at
    slice(
    	split(
    		outputs('Compose'),
    		decodeUriComponent('%0A')
    	)[3],
    	7
    )
     
  • GTAJeff Profile Picture
    8 on at
    @Chriddle  and @Expiscornovus both work like a charm.

    What's the difference in the logic between the two expressions? 
  • Expiscornovus Profile Picture
    33,995 Most Valuable Professional on at
    The approach I shared splits twice, once on the text Phone:, the second item of that array is used to split a second time on the new line character. Finally the first item is returned of that second split.
     
    Criddle his approach splits on the new line character and uses the 4th item of that array and then uses a slice to get the phone value.
     
    Both work if your structure of data always stays the same :)
     
     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 253 Super User 2026 Season 2

#2
11manish Profile Picture

11manish 172 Super User 2026 Season 2

#3
trice602 Profile Picture

trice602 134 Super User 2026 Season 2

Last 30 days Overall leaderboard