RowSet into a String Variable
RowSet into a String Variable
- Adam_Padron
- Verified User
- Posts: 1
- Joined: Thu May 07, 2009 5:00 pm
Re: RowSet into a String Variable
If you would rather have the contents of the Rowset placed into the body of the email message without using an attachment then I would recommend upgrading to 2.0. The newer version has an additional task called Set Variable. In your case you will still need to write the CSV file first. Then you can use the Set Variable task to set a variable to the contents of that new file. In your email task you would simply refer to this new variable and the contents of the file (which is your Rowset data) will be placed into the body of the email message.
If you go this direction it is important to note that the Set Variable task will read in the entire contents of the file and store it into memory. If the file is large you will need to determine whether GoAnywhere is allocated enough memory to support it.
If you choose to upgrade to version 2.x here is an example project that will send an email with the contents of the file in the email body.
- Code: Select all
<project name="RowsetEmail" mainModule="Main" version="1.0">
<module name="Main">
<setVariable name="data" inputFile="/linoma/goanywhere/userdata/documents/administrator/xml/EMP.csv" />
<sendEmail resourceId="Linoma SMTP Server" toList="support@linoma.com">
<from address="support@linoma.com" />
<subject>
<![CDATA[Subject]]>
</subject>
<message>
<![CDATA[${data}]]>
</message>
</sendEmail>
</module>
</project>
- Support_Steve
- Support Specialist
- Posts: 13
- Joined: Fri May 08, 2009 7:59 am
Re: RowSet into a String Variable
- Support_Erick
- Support Specialist
- Posts: 8
- Joined: Thu Mar 05, 2009 9:20 am
Who is online
Users browsing this forum: No registered users and 0 guests