How to getmail id from mail body in gmail account?

Hi,
I want to get mail id from the mail body from gmail account. Like:-"xxx@xxx.com".

Is there any any idea for getting mail id from mail body??

Hi @sarvam,

Email.Sender.Address, E-mail.From.Address

Regards,
Arivu

@sarvam, Refer this,

Regards,
Dominic :slight_smile:

Thanks for response to query @arivu96,
But I want mail id from body of mail.

like:- in mail body
snskcnl
cknclk
dkclk
xyz@xxx.com

I want to get/read only mail-id from body.

Can you please give another solution for same.

Hi @sarvam,

use Regex expression to get the mail id from the string.

Refer

Regards,
Arivu

@arivu96 @Dominic
How can I retrieve mail-id from mail body using β€œMatches” activity with regex.??

Hi @sams,

Use Matches activity
Properties
Input β†’ strvalue
Pattern β†’ [a-zA-Z0-9-_.]+@[a-zA-Z.]+
Result β†’ Ienum variable IEnumerable

using for each you can get all the mail ids.
if you want to get first mail id, use below code
Ienum(0).Tostring

Regards,
Arivu :slight_smile:

Thanks @arivu96, Its work.