cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MohamedGrt
New Member

How to send emails to certain users based on ID

Hi everyone,

So I am looking into how to send certain values to specific emails based on ID. for instance: I want to send (VALUE 1 & VALUE 2) when a person sends me an email indicating his/her ID, and send back the values to the allocated email, I believe it could be done using Power Automate, but I am not sure about the right workflows used, any support will be appreciated.

 

MohamedGrt_0-1659017149631.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
fchopo
Super User
Super User

Hi @MohamedGrt 

You could do the following:

1) When a new mail arrives with a Subject like "User ID: 2"

2) Get the User ID from Subject, using the expression:

replace(triggerOutputs()?['body/subject'],'User ID:','')

3) Show the excel rows filtering by ID

4) For each row (there's only one), send an email with value 1 and value 2

 

excel-filter.png

 

Hope that helps!

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

View solution in original post

6 REPLIES 6
fchopo
Super User
Super User

Hi @MohamedGrt 

We would need a more clear explanation:

a) "I want to send (VALUE 1 & VALUE 2) when a person sends me an email indicating his/her ID": Where is this ID indicated? In the body of the email? In the subject?

Regards,

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

Hi @fchopo 

 

lets say in the Subject as it seems more convenient for the sender and the system to understand i would assume.

Thank you in advance

 

Mohamed

fchopo
Super User
Super User

Hi @MohamedGrt 

You could do the following:

1) When a new mail arrives with a Subject like "User ID: 2"

2) Get the User ID from Subject, using the expression:

replace(triggerOutputs()?['body/subject'],'User ID:','')

3) Show the excel rows filtering by ID

4) For each row (there's only one), send an email with value 1 and value 2

 

excel-filter.png

 

Hope that helps!

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

Thank you @fchopo 

In the Compose step, I could not find the "Replace" expression and therefore I had to copy and paste it.

However, the error I encountered did not target that step but the "list rows" one,

I can't see the statement written in Filter Query and I think the error resides there.

MohamedGrt_0-1659524662599.png

MohamedGrt_1-1659524687523.png

 

Here is a snapshot of the error

 

MohamedGrt_2-1659525032770.png

 

Hello again @fchopo 

 

Thanks a bunch for the support. it worked!!!

 

Best,

 

Mohamed

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Community Calls Conversations

Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Users online (2,300)