How to get suite execution results log details in the Email body?

Ask general questions here.
rahilshaikh20
Posts: 2
Joined: Fri Jul 26, 2019 8:49 am

How to get suite execution results log details in the Email body?

Post by rahilshaikh20 » Fri Jul 26, 2019 8:54 am

Hello,

I am trying to get the report log details (with the css, the pie chart diagram) after execution in the Email body instead of attachements.
I already have a module where it sends the reports as log and pdf files but the email body is empty.

Please let me know how can I modify my email module to get the data from .rxlog reports, after execution, in the Email body instead of attachements

User avatar
RobinHood42
Posts: 302
Joined: Fri Jan 09, 2015 3:24 pm

Re: How to get suite execution results log details in the Email body?

Post by RobinHood42 » Tue Jul 30, 2019 9:02 am

Hi,
I am trying to get the report log details (with the css, the pie chart diagram)
This is not possible, the email could just display the pure HTML, which you would need to create, at the best.

To retrieve the log information, stored within the *.report.data file, you would need to create your own XML parser to fetch needed data: C# XML parser

As you might already noticed, your requirements will go hand in hand with some major modifications and implementations. Not related to Ranorex, but to C# and XML parsing in general.

Cheers,
Robin

rahilshaikh20
Posts: 2
Joined: Fri Jul 26, 2019 8:49 am

Re: How to get suite execution results log details in the Email body?

Post by rahilshaikh20 » Wed Jul 31, 2019 2:16 pm

Thanks for the prompt reply.
So is it possible to print a line in email body with some HTML formatting?

For Ex: I have below code which prints Passed count in Email body.
I would like to change the font, color and print in in a table(if possible).

EmailLibrary.SendEmail(
this.Subject,
this.To,
this.From,
this.Body +=Environment.NewLine+"Total no. of passed test-scripts: "+Globals.PassedCount+

Kindly assist.