<?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: ods tagsetxp -Error while opening the file in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463232#M117983</link>
    <description>&lt;P&gt;i am attaching the excel to email and same warning pops up..even when using xlm/xls/xlsx..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;title ' ';&lt;BR /&gt;filename outbox&lt;BR /&gt;email&lt;BR /&gt;to=('xxx.y@xxx.com.au')&lt;BR /&gt;type='text/html'&lt;BR /&gt;subject="Data Driven Alerts &amp;amp;curr_date."&lt;BR /&gt;from='xxx.y@xxx.com.au'&lt;BR /&gt;attach=("\\Portfolio Analytics\Reporting\Analytics\BPB\Temp_raj\Data Dashboard.xlsx");&lt;BR /&gt;ods html body=outbox rs=none;&lt;/P&gt;&lt;P&gt;DATA _NULL_;&lt;BR /&gt;File print;&lt;BR /&gt;put 'Hi All,';&lt;BR /&gt;put ;&lt;BR /&gt;put "Please check the attachment for alert criteria for &amp;amp;curr_date.";&lt;BR /&gt;put ;&lt;BR /&gt;put ;&lt;BR /&gt;put 'Regards,';&lt;BR /&gt;put 'RRR Team';&lt;BR /&gt;put ;&lt;BR /&gt;put 'This is an automatically generated email.';&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;ods html close;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Issue is:I can open the file and output seems all good only problem with the message&amp;nbsp; pop ups.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The file format and extension of 'Data Dashboard.xls' don't match........................&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 18 May 2018 07:32:29 GMT</pubDate>
    <dc:creator>BaalaRaaji</dc:creator>
    <dc:date>2018-05-18T07:32:29Z</dc:date>
    <item>
      <title>ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463221#M117973</link>
      <description>&lt;P&gt;Hi There,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;below is the code am running...i can get the output in excel but while opening its giving the below error&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;%macro Rep_excel;&lt;BR /&gt;ods path(prepend) CDA_USER.templat(update);&lt;BR /&gt;ODS LISTING CLOSE;&lt;BR /&gt;ODS tagsets.excelxp FILE="\\aunsw0170020\Data\Restricted\PFS\ICC Personal Finance\CCSDept\CCSUser\Data Dashboard.xls"&lt;BR /&gt;STYLE= serifprinter&lt;BR /&gt;options (FitToPage = 'yes' embedded_titles = 'yes' /*skip_space='0,0,0,0,0' */ missing=' ') ;&lt;BR /&gt;ods escapechar="^";&lt;/P&gt;&lt;P&gt;%excelrep(Monthly,Mnt,&amp;amp;curr_date,&amp;amp;prev_date );&lt;BR /&gt;%excelrep(Yearly,yr,&amp;amp;curr_date,&amp;amp;last_yr_date);&lt;BR /&gt;%excelrep(Quartely,Quart1,&amp;amp;firstq,&amp;amp;secq);&lt;BR /&gt;%excelrep(Quartely,Quart2,&amp;amp;thirdq,&amp;amp;fourthq);&lt;BR /&gt;ods tagsets.excelxp close;&lt;/P&gt;&lt;P&gt;%mend;&lt;BR /&gt;%Rep_excel;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Message i get while opening the file:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The file format and extension of 'Data Dashboard.xls' don't match.The file could be corrupted or unsafe.Unless you trust its source,don't open it.Do you want to open it anyway?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can help appreciated..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 07:02:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463221#M117973</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-18T07:02:50Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463225#M117977</link>
      <description>&lt;P&gt;i did tried using xml instead of xls but still its not working...any help is much appreciated.thanks&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 07:13:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463225#M117977</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-18T07:13:40Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463229#M117980</link>
      <description>&lt;P&gt;The clue, as always, is given in the warning message (which is by the way an Excel warning).&lt;/P&gt;
&lt;P&gt;"&lt;SPAN&gt;The file format and extension of 'Data Dashboard.xls' don't match."&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;What you should understand, which is unfortunately lost to the mists of time, is that file extensions - the part after the dot - tell the operating system what program to open the file with (file association), and the opening program what the format is.&amp;nbsp; Now:&lt;BR /&gt;XLS - this is a proprietary file format created by MS for Excel up to around the 2007 release of Office when they changed to XLSX. This is a very old format, and not good at portability or compatability, and really shouldn't be used any more.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;XLSX - this is a proprietary Open Office document file, it is in fact a zip with some XML files in it.&amp;nbsp; It is the default Excel file format now.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Now what you are creating from your ods statement is tagset output.&amp;nbsp; This is XML which has various tags and such like that Excel can read and parse, but it is&amp;nbsp;&lt;U&gt;&lt;STRONG&gt;not&lt;/STRONG&gt;&lt;/U&gt; an XLS or XLSX file, it is an XML file.&amp;nbsp; Therefore what Excel is telling you is that the file extension is telling me I am to expect a binary XLS file, but instead when I read it, I get a text XML file, this does not match.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Call your file extension the code for what the file is:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;ods tagsets.excelxp file="\\aunsw0170020\Data\Restricted\PFS\ICC Personal Finance\CCSDept\CCSUser\Data Dashboard.xml"&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Then you will not get this warning.&amp;nbsp; Do note however that due to file associations, .xml may open in browser, or in XML application etc.&amp;nbsp; but you can change this (if you really want to) by right clicking on the file and choosing open with and selecting Excel.&amp;nbsp; If you want to create native XLSX then 9.4 has libname xlsx.&amp;nbsp; And if you want native (aaarrrghhh really bad) XLS format, then use proc export.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Edit:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;"i did tried using xml instead of xls but still its not working" - posting it did not work does not help, we need information as to what, how etc.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 07:22:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463229#M117980</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-05-18T07:22:41Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463232#M117983</link>
      <description>&lt;P&gt;i am attaching the excel to email and same warning pops up..even when using xlm/xls/xlsx..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;title ' ';&lt;BR /&gt;filename outbox&lt;BR /&gt;email&lt;BR /&gt;to=('xxx.y@xxx.com.au')&lt;BR /&gt;type='text/html'&lt;BR /&gt;subject="Data Driven Alerts &amp;amp;curr_date."&lt;BR /&gt;from='xxx.y@xxx.com.au'&lt;BR /&gt;attach=("\\Portfolio Analytics\Reporting\Analytics\BPB\Temp_raj\Data Dashboard.xlsx");&lt;BR /&gt;ods html body=outbox rs=none;&lt;/P&gt;&lt;P&gt;DATA _NULL_;&lt;BR /&gt;File print;&lt;BR /&gt;put 'Hi All,';&lt;BR /&gt;put ;&lt;BR /&gt;put "Please check the attachment for alert criteria for &amp;amp;curr_date.";&lt;BR /&gt;put ;&lt;BR /&gt;put ;&lt;BR /&gt;put 'Regards,';&lt;BR /&gt;put 'RRR Team';&lt;BR /&gt;put ;&lt;BR /&gt;put 'This is an automatically generated email.';&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;ods html close;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Issue is:I can open the file and output seems all good only problem with the message&amp;nbsp; pop ups.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The file format and extension of 'Data Dashboard.xls' don't match........................&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 07:32:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463232#M117983</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-18T07:32:29Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463235#M117986</link>
      <description>&lt;P&gt;I can't tell you anything other than what I have said, your error:&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The file format and extension of 'Data Dashboard.xls' don't match.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Tells me that the file is still called xls which it is not, and the code you provide is attaching and XLSX.&amp;nbsp; You need to create an XML file from your ods statement, and attach the XML file to your email. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Although, I really recommend not using email for sending files, file size tends to break email, its not secure, etc.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 07:40:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463235#M117986</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-05-18T07:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463239#M117990</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/44464"&gt;@BaalaRaaji&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;i am attaching the excel to email and same warning pops up..even when using xlm/xls/xlsx..&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;title ' ';&lt;BR /&gt;filename outbox&lt;BR /&gt;email&lt;BR /&gt;to=('xxx.y@xxx.com.au')&lt;BR /&gt;type='text/html'&lt;BR /&gt;subject="Data Driven Alerts &amp;amp;curr_date."&lt;BR /&gt;from='xxx.y@xxx.com.au'&lt;BR /&gt;attach=("\\Portfolio Analytics\Reporting\Analytics\BPB\Temp_raj\Data Dashboard.xlsx");&lt;BR /&gt;ods html body=outbox rs=none;&lt;/P&gt;
&lt;P&gt;DATA _NULL_;&lt;BR /&gt;File print;&lt;BR /&gt;put 'Hi All,';&lt;BR /&gt;put ;&lt;BR /&gt;put "Please check the attachment for alert criteria for &amp;amp;curr_date.";&lt;BR /&gt;put ;&lt;BR /&gt;put ;&lt;BR /&gt;put 'Regards,';&lt;BR /&gt;put 'RRR Team';&lt;BR /&gt;put ;&lt;BR /&gt;put 'This is an automatically generated email.';&lt;BR /&gt;run;&lt;/P&gt;
&lt;P&gt;ods html close;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Issue is:I can open the file and output seems all good only problem with the message&amp;nbsp; pop ups.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The file format and extension of 'Data Dashboard.xls' don't match........................&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You use file Portfolio Analytics\Reporting\Analytics\BPB\Temp_raj\Data Dashboard.xlsx in the email, &lt;STRONG&gt;WHICH IS NOT CORRECTLY NAMED AS XML&lt;/STRONG&gt;!&lt;/P&gt;
&lt;P&gt;But then Excel still complains about "&lt;SPAN&gt;Data Dashboard.xls&lt;/SPAN&gt;", &lt;STRONG&gt;WHICH IS NOT THE FILE YOU SENT ANYWAY&lt;/STRONG&gt;!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Repeating the same mistake again and again CANNOT lead to a different outcome (see Einstein's definition of insanity)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;create the output from tagsets.excelxp with a &lt;EM&gt;.xml&lt;/EM&gt; extension&lt;/LI&gt;
&lt;LI&gt;attach &lt;EM&gt;exactly&lt;/EM&gt; that file to the email&lt;/LI&gt;
&lt;LI&gt;make sure that &lt;EM&gt;exactly&lt;/EM&gt; that file is opened in Excel&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Fri, 18 May 2018 08:06:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463239#M117990</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-05-18T08:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463247#M117997</link>
      <description>Kurt Bremser&lt;BR /&gt;have tried number of times...by using same extension..either XML/xls/xlsx in the code and also in email part of the code...please advise if you know the solution..&lt;BR /&gt;&lt;BR /&gt;RW9....problem is not with file size..we can use ODs package to archive and to reduce file size (zip)...AS said I have tried xml version too...same warning pop ups...</description>
      <pubDate>Fri, 18 May 2018 08:22:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463247#M117997</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-18T08:22:49Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463248#M117998</link>
      <description>Not sure if you guys understand the query or not...you can try with the code and can help me to fix the warning msg</description>
      <pubDate>Fri, 18 May 2018 08:25:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463248#M117998</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-18T08:25:22Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463249#M117999</link>
      <description>&lt;P&gt;I will try once more.&amp;nbsp; On your local machine (forget the email part for the time being) run this bit of SAS code:&lt;/P&gt;
&lt;PRE&gt;ods tagsets.excelxp file="&amp;lt;put path here&amp;gt;/test.xls";
proc print data=sashelp.class;
run;
ods tagsets.excelxp close;&lt;/PRE&gt;
&lt;P&gt;Change the &amp;lt;put path here&amp;gt; to somewhere local.&amp;nbsp; Then open this test.xls file you saved locally.&amp;nbsp; You will get the warning from Excel.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now, with exactly the same code:&lt;/P&gt;
&lt;PRE&gt;ods tagsets.excelxp file="&amp;lt;put path here&amp;gt;/test.xml";
proc print data=sashelp.class;
run;
ods tagsets.excelxp close;&lt;/PRE&gt;
&lt;P&gt;Only changing the file extension to xml, then opening the test.xml with Excel, you will not get the warning.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 08:33:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463249#M117999</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-05-18T08:33:14Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463251#M118001</link>
      <description>&lt;P&gt;WHICH code?&lt;/P&gt;
&lt;P&gt;You have provided several snippets that use different filenames. Post the whole code you ran in one piece, so we can re-execute it as is.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For reference: I ran this code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ODS tagsets.excelxp FILE="$HOME/sascommunity/class.xml"
STYLE= serifprinter
options (FitToPage = 'yes' embedded_titles = 'yes' /*skip_space='0,0,0,0,0' */ missing=' ') ;
ods escapechar="^";

proc print data=sashelp.class;
run;

ods tagsets.excelxp close;

filename outbox
email
to=('username@domain.com')
type='text/html'
subject="Test"
attach=("$HOME/sascommunity/class.xml");

ods html file=outbox;

DATA _NULL_;
File print;
put 'Hi All,';
put ;
put ;
put ;
put 'Regards,';
put 'RRR Team';
put ;
put 'This is an automatically generated email.';
run;

ods html close;

filename outbox clear;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;(only the email address is changed)&lt;/P&gt;
&lt;P&gt;I received that email in my inbox, saved the attachment to my desktop, and opened it with MS Excel (or by using the Office XML Handler) without any problems or messages.&lt;/P&gt;
&lt;P&gt;This is the log from the code:&lt;/P&gt;
&lt;PRE&gt;27         ODS tagsets.excelxp FILE="$HOME/sascommunity/class.xml"
28         STYLE= serifprinter
29         options (FitToPage = 'yes' embedded_titles = 'yes' /*skip_space='0,0,0,0,0' */ missing=' ') ;
NOTE: Writing TAGSETS.EXCELXP Body file: $HOME/sascommunity/class.xml
Unrecognized option: MISSING
NOTE: This is the Excel XP tagset (Compatible with SAS 9.1.3 and above, v1.131, 04/23/2015). Add options(doc='help') to the ods 
statement for more information.
30         ods escapechar="^";
31         
32         proc print data=sashelp.class;
33         run;

NOTE: There were 19 observations read from the data set SASHELP.CLASS.
NOTE: The PROCEDURE PRINT printed page 1.
NOTE: PROCEDURE PRINT used (Total process time):
      real time           0.11 seconds
      cpu time            0.02 seconds
      

34         
35         ods tagsets.excelxp close;
36         
37         filename outbox
38         email
39         to=('username@domain.com')
40         type='text/html'
41         subject="Test"
42         attach=("$HOME/sascommunity/class.xml");
43         
44         ods html file=outbox;
NOTE: Writing HTML Body file: OUTBOX
45         
46         DATA _NULL_;
47         File print;
48         put 'Hi All,';
49         put ;
50         put ;
51         put ;
52         put 'Regards,';
53         put 'RRR Team';
54         put ;
55         put 'This is an automatically generated email.';
56         run;

NOTE: 5 lines were written to file PRINT.
NOTE: The DATA step printed page 2.
NOTE: DATA statement used (Total process time):
      real time           0.01 seconds
      cpu time            0.00 seconds
      

57         
58         ods html close;
Message sent
      To:          'username@domain.com'
      Cc:          
      Bcc:         
      Subject:     Test
      Attachments: ( "$HOME/sascommunity/class.xml" )
59         
60         filename outbox clear;
NOTE: Fileref OUTBOX has been deassigned.
&lt;/PRE&gt;
&lt;P&gt;once again, only the email address was anonymized.&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 08:46:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463251#M118001</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-05-18T08:46:04Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463346#M118045</link>
      <description>&lt;P&gt;Before I opened this thread I was certain this was going to involve: &lt;STRONG&gt;tagsets.Excelxp&lt;/STRONG&gt; and that someone created an output file with an extension other than &lt;STRONG&gt;XML. &lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;XLS is also so old why are you attempting to abuse the data that way?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might investigate if ODS EXCEL will work for you. If so use it to create XLSX files natively.&lt;/P&gt;</description>
      <pubDate>Fri, 18 May 2018 14:06:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463346#M118045</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-05-18T14:06:55Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463683#M118173</link>
      <description>&lt;P&gt;following your steps..i have updated with xml formst and&amp;nbsp; can open the file through excel without warnings..cheers for that..&lt;/P&gt;&lt;P&gt;But now again new issue..:-)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have got 3 proc print output data for each sheets to&amp;nbsp; save&amp;nbsp; by monthly/yearly/quartely... by sheet names...however&amp;nbsp; when i put xml ..its saving into different sheets for each proc print output...monthly1 monthly2 monthly3,yearly1 yearly2,yearly3....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;hope you understood..&lt;/P&gt;&lt;P&gt;any thoughts on it..?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 21 May 2018 00:07:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463683#M118173</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-21T00:07:35Z</dc:date>
    </item>
    <item>
      <title>Re: ods tagsetxp -Error while opening the file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463687#M118175</link>
      <description>&lt;P&gt;i figured it out..its working..thank you all..appreciate your help guys...thanks&lt;/P&gt;</description>
      <pubDate>Mon, 21 May 2018 00:28:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/ods-tagsetxp-Error-while-opening-the-file/m-p/463687#M118175</guid>
      <dc:creator>BaalaRaaji</dc:creator>
      <dc:date>2018-05-21T00:28:56Z</dc:date>
    </item>
  </channel>
</rss>

