cancel
Showing results for 
Search instead for 
Did you mean: 

Send table/paste table in email using Mapiex or SMTP

KaranJuneja
Level 3
I need to send a data table in the email. I can see any action in Mapiex business object or Pop3 object which can do that. Is there a workaround or any other business object that can help me do that?
4 REPLIES 4

MelissaSuarez_G
Level 6
You will have to configure an HTML message and use the appropriate tags to specify the columns and rows (tr, td...) Here you can see an example of how these tags could be used: https://html-cleaner.com/html-table-generator/ But you can generate those tags dynamically if the number the rows changes for every email that you send.

BathulaSriniva1
Level 2
Would please suggest how to configure HTML Message using MAPIEX

MelissaSuarez_G
Level 6
All you have to do is enclose the message between the HTML tags that you want to use and use it as the ""Message"" input of the MAPIEx VBO. For example, something like...                  This is your message. ...would generate a message with bold letters like:                  This is your message. Make sure that you are using the VBO that is compatible with HTML. You can find it in this portal using the menu Products > VBOs.

Naga_DurgaJakka
Level 3
​There is an easy option with smtp pop3 instead of using code stage.
1)For smtp/pop3 vbo set flag as True for BodyIsHtml Input.
2) If you want test with static table. Take a html code and paste it in " "  and send email it works. Now since we want to get data from collection. We need to add few more steps.
    So to add values to table dynamically from collection, instead of manually adding each row dynamically. Take a loop and then calc stage to add Collection rows to the table.
Add the below format in the calc And result store in Data Item "Body"..HTMLHeader will have html code till the table rows are added.

[HTML Header]& "<tr><td>" & [Collection.Col1] & "</td> <td>" & [Collection.Col2] & "</td></tr>" & NewLine()

So this will have collection in loop and iterates till collection ends. so we have the html code for all rows of table and finally we need html end part.
3)Now take one final calculation stage and put the html in " " and data items using &. This Calc is to get all the html pieces together {HTML Header}+{HTML BODY)+{HTML END} and store in "Body"
4)Now use this body to send email.
Note:- Best way is to open w3schools html editor and try diff tags. copy paste same code in Calc between " " and try.

------------------------------
Naga Durga
RPA Modeller
America
------------------------------