<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Emailing via ODS in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60078#M7186</link>
    <description>So, just to be clear as mud, you are seeing SAS-generated HTML code in your EMAIL. So that means your EMAIL client is not detecting the EMAIL as being HTML-formatted. This condition only occurs for me when I forget to code the TEXT= parameter.  So, please share (in a post to the list) the exact FILENAME and ODS HTML statement you are executing for feedback.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
    <pubDate>Thu, 06 Nov 2008 19:41:50 GMT</pubDate>
    <dc:creator>sbb</dc:creator>
    <dc:date>2008-11-06T19:41:50Z</dc:date>
    <item>
      <title>Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60072#M7180</link>
      <description>Hi,&lt;BR /&gt;
&lt;BR /&gt;
is there a way of emailing a small dataset via the ODS,&lt;BR /&gt;
i did find a bit of script to do it but this caused a thousand and one errors and when i finally got it to email something, it was all text and no formatting. So i gave up on that, and resorted to sending it as an attachment:&lt;BR /&gt;
&lt;BR /&gt;
filename doemail email &lt;BR /&gt;
	to= 'to@me.com'&lt;BR /&gt;
	from='from@me.com'&lt;BR /&gt;
	subject="&amp;amp;emailsubject."&lt;BR /&gt;
	attach="C:\stuff\DailyTop5_&amp;amp;wordsday..xls";&lt;BR /&gt;
     &lt;BR /&gt;
data _null_;&lt;BR /&gt;
	file doemail;&lt;BR /&gt;
		put 'Hi All,';&lt;BR /&gt;
		put;&lt;BR /&gt;
		put "Please find attached the daily top5 figures for &amp;amp;wordsday.";&lt;BR /&gt;
		put;&lt;BR /&gt;
		put 'Thanks';&lt;BR /&gt;
	run;&lt;BR /&gt;
&lt;BR /&gt;
This is fine but was a quick fix, now i have some time i would like it to be in the body of the email like:&lt;BR /&gt;
"&lt;BR /&gt;
Hi All&lt;BR /&gt;
&lt;BR /&gt;
here are the Daily Top 5 Figures for 06NOV2008&lt;BR /&gt;
&lt;BR /&gt;
Position  Name  Figure&lt;BR /&gt;
1            Rod     150&lt;BR /&gt;
2            Jane    120&lt;BR /&gt;
3            Freddy 119&lt;BR /&gt;
4            Zippy   100&lt;BR /&gt;
5            George 62&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
"&lt;BR /&gt;
obviously i would like the table to be an actual table.&lt;BR /&gt;
&lt;BR /&gt;
any ideas?&lt;BR /&gt;
&lt;BR /&gt;
thanks</description>
      <pubDate>Thu, 06 Nov 2008 14:32:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60072#M7180</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2008-11-06T14:32:59Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60073#M7181</link>
      <description>Review the use of TYPE= parameter on your FILENAME when sending "formatted" output imbedded in your EMAIL body.  There are examples on the SAS support website.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
      <pubDate>Thu, 06 Nov 2008 14:51:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60073#M7181</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2008-11-06T14:51:26Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60074#M7182</link>
      <description>If your observations are in a SAS dataset, you can PROC PRINT them as follows:&lt;BR /&gt;
&lt;BR /&gt;
ODS HTML FILE=DOEMAIL;&lt;BR /&gt;
&lt;BR /&gt;
PROC PRINT DATA=RESULTS;&lt;BR /&gt;
 VAR NAME VALUE;&lt;BR /&gt;
RUN; &lt;BR /&gt;
&lt;BR /&gt;
ODS HTML CLOSE;&lt;BR /&gt;
&lt;BR /&gt;
The above works because HTML is a valid format for emails. &lt;BR /&gt;
&lt;BR /&gt;
Because I run my work on the z/OS platform, my opening ODS HTML statement also has the RS=NONE STYLE=MINIMAL options.&lt;BR /&gt;
&lt;BR /&gt;
You may be able to use TITLE and FOOTNOTE statements to get other text on the page. If not, you may need DATA steps as in your example before and after PROC PRINT (between the ODS HTML pair).</description>
      <pubDate>Thu, 06 Nov 2008 14:58:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60074#M7182</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2008-11-06T14:58:01Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60075#M7183</link>
      <description>Hi I have tried this and it doesnt display as html it is text.&lt;BR /&gt;
i have checked my outlook to display as html.&lt;BR /&gt;
If i copy what is emailed to me and open it in a html viewer it looks like the way i want it&lt;BR /&gt;
this is very strange, any help will be much appreciated?

Also could this be to do with every time i run this script outlook comes up with the warning prompt, saying allow or deny?&lt;BR /&gt;
    &lt;BR /&gt;
Message was edited by: Spud</description>
      <pubDate>Thu, 06 Nov 2008 15:14:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60075#M7183</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2008-11-06T15:14:35Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60076#M7184</link>
      <description>I, too, missed out the TYPE parameter mentioned above. Try&lt;BR /&gt;
&lt;BR /&gt;
FILENAME DOEMAIL . . . TYPE="TEXT/HTML" ;</description>
      <pubDate>Thu, 06 Nov 2008 15:49:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60076#M7184</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2008-11-06T15:49:26Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60077#M7185</link>
      <description>This still only displays as text.....</description>
      <pubDate>Thu, 06 Nov 2008 17:18:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60077#M7185</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2008-11-06T17:18:38Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60078#M7186</link>
      <description>So, just to be clear as mud, you are seeing SAS-generated HTML code in your EMAIL. So that means your EMAIL client is not detecting the EMAIL as being HTML-formatted. This condition only occurs for me when I forget to code the TEXT= parameter.  So, please share (in a post to the list) the exact FILENAME and ODS HTML statement you are executing for feedback.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
      <pubDate>Thu, 06 Nov 2008 19:41:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60078#M7186</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2008-11-06T19:41:50Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60079#M7187</link>
      <description>Morning&lt;BR /&gt;
&lt;BR /&gt;
filename doemail email &lt;BR /&gt;
	to= 'to@me.com'&lt;BR /&gt;
	from='from@mecom'&lt;BR /&gt;
	subject="&amp;amp;emailsubject."&lt;BR /&gt;
	attach="c:\myfile.xls"&lt;BR /&gt;
TYPE="TEXT/HTML";&lt;BR /&gt;
&lt;BR /&gt;
ODS HTML FILE=DOEMAIL;&lt;BR /&gt;
&lt;BR /&gt;
PROC PRINT DATA=myfile;&lt;BR /&gt;
RUN;&lt;BR /&gt;
&lt;BR /&gt;
ODS HTML CLOSE;&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
Simon</description>
      <pubDate>Fri, 07 Nov 2008 09:58:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60079#M7187</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2008-11-07T09:58:35Z</dc:date>
    </item>
    <item>
      <title>Re: Emailing via ODS</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60080#M7188</link>
      <description>I use a similar coding technique as you have shared, except the ODS parameter parameter is coded to prevent HTML tag truncation.&lt;BR /&gt;
&lt;BR /&gt;
So, again, the question: are you seeing HTML code in the EMAIL you receive or a text reporting listing?  Also, has the code (or something similar) ever worked previously where you send SAS-generated HTML reports via EMAIL?&lt;BR /&gt;
&lt;BR /&gt;
And, mention again, the sending and receiving operating system environments, EMAIL client?  Also, your SAS version and service pack / HOTFIX maintenance levels are something to consider.&lt;BR /&gt;
&lt;BR /&gt;
Also, consider an attempt without the ATTACH= parameter to determine any different SAS behavior with your EMAIL content.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
      <pubDate>Fri, 07 Nov 2008 13:55:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Emailing-via-ODS/m-p/60080#M7188</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2008-11-07T13:55:25Z</dc:date>
    </item>
  </channel>
</rss>

