Can't read mail.Body IBM Notes

Hello All,

I have a question regarding Email Activities.

The Bot I am developing, receives an Email to its IBM Notes Account. This Email is automatically generated by a Website everytime a customer fills in information. The Email contains about 5 Lines of text with some standardized information and a table with the data filled in by the customer. It is not very big in size.

When reading the Email, I can retrieve the mail.Subject and the mail.Sender without Problems. The mail.Body though, returns an empty string eventhough it is not empty.

After researching some previously posted questions, I am clueless. I have tried retrieving the mail.Body through mail.Headers(“HTML”).ToString which returns an error. mail.Headers(“PlainText”) returns an empty string as well.

I have tried saving the Email to a .mht, .txt or .html File and then opening it and working with that. The problem here is that only the first 1-2 lines of the Mail.Body are saved. The rest somehow gets lost.

The encoding of the Email Body is us-ascii, which is weird cause the Subject is UTF-8, as it should be according to the Developer of the Website that generates the Emails.

What is also interesting is that when analyzing the Email-Content, the Content-Type returns text/html. So it appears to be a combination of both.

Even more interestingly, when I forward the Email to the same Inbox (Send the Email from the same Account), the Bot is able to read the mail.Body without any Problems…

Anyone has any additional ideas on what else I could try?

Thanks a lot in advance.


Hey @chusikowski

What is the version of activities?

Also please show a snap of the email !


Hi Nithin,

thanks for your reply. The version of actvities is:


I have tried downgrading the Mail.Activities package, sadly without any success.

1 Like

Hey @chusikowski

I feel there is some formatting related issue.

Kindly update your email with simulated content and please attach the mail here.

Let’s analyse.


Hey @chusikowski

You got the solution, If not please attach the sample.


Hi @Nithinkrishna,

I managed to solve the issue by connecting to the Mail DB via code.

Dim sesMain As New Domino.NotesSession
Dim dir As Domino.NotesDbDirectory = sesMain.GetDbDirectory("")
ndbMail = dir.OpenMailDatabase

Then the email doesn’t get formatted when reading it through UiPath.


Good @chusikowski

Valuable learning for us as well, thanks for sharing

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.