Outlook mail body contains URL,Need to hit on that URL

Hi All,

I my email i use to get scheduled reports link in the mail body, I need to hit on that link so that i can download the data. How to do that, Sample xaml file will be helpful for better understanding.

Link Syntax:
Link will be change in every email.

You can try this way :

  1. String body = mail.Body;

  2. "\S*(http|https)\S*" in Regex Matches Activity


  1. if (matchfound.Count>0)
    strURL = matchfound(0).ToString() β€”> If expecting only 1 URL else use For Each loop

  2. Open Browser -----> strURL

1 Like

Hi VVaidya,

Thanks for your quick reply, But iam sorry really i didnt get how to work
on it .

Please can you upload sample xaml file, it will be helpful for me to
understand in a better way.because first we need to search unread mail in
that we need to catch recent email with subject name, once we filter mail
with subject in that mail body it contains url link , we need to click on
that link then our raw data will get downloaded.

Have you gone through the academy training?If so, you should be able to perform this task easily.

Please go through if you have time : academy.uipath.com

There are many topics related to this subject, please refer them. Thanks.

1 Like

Yes, I have gone through E mail automation concept, also i have prepared one project for downloading an attchment file , my using mail.netmail message concept.
But for reading body mail link , iam not getting idea how to link it.


Can you give me a sample xaml file for this one :slight_smile:

Thanks in advance .

Hi @nirsha,

Here we go for sample solution to find the URL in the mail and open it in browser:
ClickOnHyperlinkOutlookMail.xaml (11.9 KB)


1 Like

Its working fine :slight_smile: Thank you so much :slight_smile:

I tried with Xaml,It’s working fine for only one mail with hyperlink,if multiple mails are present other hyperlinks are not opened

Hi All,

I am unable to find a solution for clicking on URL in email Body. Have tried suggested solutions in the forum - still not resolved, please help.
Below is my flow:

Matches Property


Email Body Format: