cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
chhe
Helper III
Helper III

Check if Email is related to person

Hello,

 

I have a flow that creates a element in a sharepoint list everytime a email comes in. The sender of this email should be stored in a "person/group" column. No problem until here.

 

But there also are email with a sender that has no outlook profile or comes from a external sender. In this situation the flow fails, because the person can not be found. In this case I want to store the email in another column (text).

 

How can I check if the email is related to a person / outlook profile?

1 ACCEPTED SOLUTION

Accepted Solutions

Hi,

 

thanks for your help. The solution abm does not work for me, because the the step "Get User Profile" is successfull in both cases. 

I have put a condition after the "Get User Profile" and Check if the account is activated.

 

This works for me. Thank you!

View solution in original post

6 REPLIES 6
ChristianAbata
Super User
Super User

hi @chhe  you can add a contidition to see if the email not contains your domain org, so for every domain like hotmail, or gmail or external in general mails.

cont.PNG



Did I answer your question? Please consider to Mark
my post as a solution! to guide others :winking_face:

Proud to be a Flownaut!


If you want you can follow me at www.christianabata.com Quieres contenido en español? Síguenos en Power Automate LA
abm
Super User
Super User

Hi @chhe 

 

You can utilise the flow exception handling to do this. Please follow this

 

image.png

 

 

Set the configure run after as follows: (Click on three dot on action step. Click configure run after, set the following)

 

image.png

 

Finally you can use the variable IsUserProfileFound to decide whether profile found or not.

 

Please see my blog post related to exception handling in flow. Really useful feature especially in these situations for business continuity.

https://www.powerautomatetraining.co.uk/post/power-automate-how-to-find-a-folder-exists-dynamic-in-s...

 

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

Hi,

 

thanks for your help. The solution abm does not work for me, because the the step "Get User Profile" is successfull in both cases. 

I have put a condition after the "Get User Profile" and Check if the account is activated.

 

This works for me. Thank you!

View solution in original post

Hi @chhe 

 

Thanks for the response.

 

You mentioned that email with a sender that has no outlook profile or comes from a external sender, based on that I assumed that no profile is found.  I wondered how it gets successful? 

 

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

I don't know why it gets successfull. I have tested it now with a with a group email from my organisation. With this email the get profile works. I haven't tested it with an external email yet, but for this I think I will add a step after "get profile" that runs if the "get profile" fails.

Hi @chhe 

 

Try to test with the external email and see if that works. You have two possible solutions here.

 

1. Follow the steps which I mentioned earlier if you have more than one domain address.

2. If your organisation has one or limited (all known) domain email address you can check the address contains the domain name (xxxx@abc.com). So here abc.com is the domain name.

 

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

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Users online (1,973)