Mailing a string table through smtp

Hi,
I have a flow service that returns a string table output which has two columns. The number of rows is determined at run-time. Now I have to mail this string table. I tried attaching the table to ‘body’ as well as ‘attachments’ field of smtp service but it didn’t send anything.
I’m new to webMethods. Any leads will be helpful.
If there is no way of sending the table as a ‘body’, what are the steps I must take to convert the table to a file(.txt or .xls) and send that as an attachment to smtp.

Hi Abhilash,

you can try to convert the table to a single string by using pub.string:objectToString and include this string to your mailbody.

Can you share your IS version?

Regards,
Holger

Hi,
Thanks, will try the same.
I’m running on 9.6

The objectToString service can’t take stringTable as its input. Any other suggestions please ?

Hi Abhilash,

eventually writing an output template might help.

See DSP_and_Output_Template_Developers_Guide for further informations about this.

Regards,
Holger

1 Like

Abhilash – you can use html format, use table tags with which you can achieve what you want.

Thanks,

Hi Abhilash,

As MR as173d said probably the best idea is to use HTML tags. At the end, I assume that you want this table to be easily readable, right?

You might find some ideas on how to do this here: http://tech.forums.softwareag.com/techjforum/posts/list/31431.page#100723

Please let us know if it works for you.

Vlad Turian