Mail activity

I have a undeliverable mail
I want to extract for which mail id
It got not delivered
I want to get the mail id from the undeliverable mail…
I used get outlook and filtered using undeliverable
And got all undeliverable mail
Now i need the undelivered mail id from each mail

Hi @Demo_User

Try this

I hope it helps!!

@Demo_User

“Get Outlook Mail Messages” activity to retrieve the undeliverable email messages
use the “Filter” property of the “Get Outlook Mail Messages” activity with a filter expression like "Subject LIKE '%undeliverable%'" .

Hi @Demo_User

I think you have used Get outlook Mail message or Get IMAP Mail message activity to retrieve the mails which is undeliverable. Output of this activities are IEnumerable of Mail Messages.

It was a collection then we want to iterate each email we have to use For each activity.

Hope it helps!!

Yes am getting mail message
I want for which id it got undelivered

@Demo_User

Please look into this

@Demo_User

Use Filter in Get OutLook Mail Messages

This i will the system id from which I got the mail for undeliverable
I want the mail id which I cant able to to send

@Demo_User

Let me know, My workflow works for you, if it doesn’t work let me know or mark as solution to close the loop

No it is returning blank value

Hi @Demo_User

Try this:


currentItem.From.ToString will return the Name and email ID
currentItem.SenderEmailAddress.ToString will return only the Email ID

Hope it helps!!

Hello @Demo_User ,

Can you try using this → currentItem.To.Item(0).Address.ToString

Hope it helps

All the condition which you all have mentioned will work for normal email
But check for undeliverable mail it wont work