How to know the email has come in Web mail and inform user

Hi All,

How to know the email has come in Webmail and inform the user using UIPath?

Please suggest if any ideas.

Thanks,
Sneha

Have you tried email activities ?

1 Like

Yes i m trying to use Get Outlook Mail Messages and then how to check after that

In the Get Outlook mail activities, in the properties,

Select this option -

OnlyUnreadMessages - Specifies whether to retrieve only unread messages. By default, this check box is selected.

After retrieving mail messages, you are saving the output to mailmessage collection object.

you can take the count of mailmessages object to know how many unread mails are available.

numOfUnreadMails = mailMessageCollectionObject.Count

You can inform the user with this count.

1 Like

Thankyou so much for your quick Reply and help…

How to inform the user by Message box or is there a way to show a popup here…

Thanks

@Snehamayi_Sneha There is a message box activity or you can use write text file activity

My bot should start execute when there is a mail in Outlook so how it can be done?

@Snehamayi_Sneha You can refer this

1 Like

Use outlook mail message activity and then change the properties of that activity like tik the read only unread mails check box and then use output_varible from mail message activity output_varible.count in if condition.

My Issue is that when a mail has come to Outlook the bot needs to recognize at that time and trigger a message to user.

when we use GetoutlookMailMessage we will get the unread mails no doubt . But how can the bot identifies when a mail has triggered to our outlook?

As my understanding, you want to trigger some message to the user when new mail is received in outlook right…
So you need to check your outlook continuously (GetoutlookMailMessage will give the unread mails right if mail is there trigger message to user use whatever logic required here and if mails not exist chek back to GetoutlookMailMessage activity in a loop)

1 Like

Thankyou…

can we show a popup window instead of Messagebox?

i thin yes by using call out activity

1 Like

Hi @Snehamayi_Sneha
For that you have to run your process continuously or you can use User events activity. if any events happened it will triggered.

I did successfully in Outlook… But i need the same thing in Webmail .

How to get mail messages from a webmail?

How to detect when an email comes to a webmail?

1 Like

@Snehamayi_Sneha
You can do it using Get IMAP mail messages activity. in this you have to provide Credentials and Port and server. Port for IMAP is 993 And Server is “imap.gmal.com”.

1 Like

Thanks let me try in this way…

So is it possible if i did not check markasread option once the bot read the unread mails… So the message box will always come for unread mails because it’s still in unread.
So is it possible when the bot runs again it should pick which is already read by the bot… Can you guide me with the logic please…
Can i compare the date n time , subject of the first unread mails store somewhere. And for the second time i will compare with the current emails date n time.

Please guide me how to proceed…

Thanks

1 Like

1.) Is check mark as read option
2.)Once your process is done moving the mail from Inbox to some other folder

Comparison of subject and date may default because may get a chance of multiple emails with same subject and time you can do this way but bit complex

Hey Kalyan,

Thankyou so much for your suggestion. I am trying to use Move the read files to different folder…Let me try if any issue reach out to you…

Thanks…

Thanks it worked for me