<?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: Export SAS dataset with DDE: Excel file with worksheet name issue in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263709#M15622</link>
    <description>&lt;P&gt;Hi William, I think&amp;nbsp;you need to enclose the sheet name in&amp;nbsp;single quotation marks when the sheet name has spaces in it:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;filename excelsys DDE&lt;STRONG&gt; "&lt;/STRONG&gt;EXCEL|&amp;lt;..path..&amp;gt;[file_name.xls]&lt;STRONG&gt;'&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;05 Quarter Performance&lt;/STRONG&gt;'&lt;SPAN&gt;!R1C6:R21C13&lt;STRONG&gt;"&lt;/STRONG&gt; notab lrecl=6000 ;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 14 Apr 2016 01:06:52 GMT</pubDate>
    <dc:creator>sophiaL</dc:creator>
    <dc:date>2016-04-14T01:06:52Z</dc:date>
    <item>
      <title>Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263698#M15621</link>
      <description>&lt;P&gt;I have export sas dataset to excel file using DDE.&lt;/P&gt;
&lt;P&gt;The code has minor issue, I coded:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;filename excelsys DDE 'EXCEL|&amp;lt;..path..&amp;gt;[file_name.xls]&lt;STRONG&gt;05 Quarter Performance&lt;/STRONG&gt;!R1C6:R21C13' notab lrecl=6000 ;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;if the tab name likes "Sheet1" without space, the code is OK. With the tab name likes above, it can not write the output and generate error message.&lt;/P&gt;
&lt;P&gt;ERROR: DDE session not ready.&lt;BR /&gt;FATAL: Unrecoverable I/O error detected in the execution of the DATA step program.&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Aborted during the EXECUTION phase.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can you give me a hint to solve this issue.&amp;nbsp; Thanks in advance.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;William&lt;/P&gt;</description>
      <pubDate>Wed, 13 Apr 2016 23:21:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263698#M15621</guid>
      <dc:creator>wtien196838</dc:creator>
      <dc:date>2016-04-13T23:21:13Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263709#M15622</link>
      <description>&lt;P&gt;Hi William, I think&amp;nbsp;you need to enclose the sheet name in&amp;nbsp;single quotation marks when the sheet name has spaces in it:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;filename excelsys DDE&lt;STRONG&gt; "&lt;/STRONG&gt;EXCEL|&amp;lt;..path..&amp;gt;[file_name.xls]&lt;STRONG&gt;'&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;05 Quarter Performance&lt;/STRONG&gt;'&lt;SPAN&gt;!R1C6:R21C13&lt;STRONG&gt;"&lt;/STRONG&gt; notab lrecl=6000 ;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 01:06:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263709#M15622</guid>
      <dc:creator>sophiaL</dc:creator>
      <dc:date>2016-04-14T01:06:52Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263716#M15623</link>
      <description>&lt;P&gt;&amp;nbsp;I did. I tried different styles: &amp;nbsp;' ' , [], () , "" (double quote to replace space) etc..&lt;/P&gt;
&lt;P&gt;None of them worked.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 01:27:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263716#M15623</guid>
      <dc:creator>wtien196838</dc:creator>
      <dc:date>2016-04-14T01:27:37Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263725#M15625</link>
      <description>&lt;P&gt;Try splitting your DDE reference.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Open workbook desired, then only need to reference sheet/cells.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've done it so know it's possible but can't access my code until later.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;See the&amp;nbsp;example here, use X command to open file, then reference sheet mean.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.ats.ucla.edu/stat/sas/faq/sas2excel_dde.htm" target="_blank"&gt;http://www.ats.ucla.edu/stat/sas/faq/sas2excel_dde.htm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 02:01:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263725#M15625</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-04-14T02:01:08Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263729#M15626</link>
      <description>&lt;P&gt;No special treatment is necessary.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;See the examples starting on Page 2.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So I think you have something else wrong. Post your full code please.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 02:17:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263729#M15626</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-04-14T02:17:23Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263790#M15629</link>
      <description>&lt;P&gt;More importantly, why are you using DDE to export to Excel? &amp;nbsp;It is very old technology, only just supported, with old functionality and doesn't work in some setups? &amp;nbsp;Try using tagsets.excelxp, export procedure, libname excel, or one of the many other far better methods to get data out to Excel - or in an ideal world don't use Excel in the first place.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 08:21:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263790#M15629</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2016-04-14T08:21:15Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263854#M15630</link>
      <description>&lt;P&gt;Reeza,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is the sample source code:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;options noxwait noxsync ;&lt;BR /&gt;&lt;BR /&gt;%let Excel_path = 'C:\Program Files (x86)\Microsoft Office\Office15\EXCEL.EXE' ;&lt;BR /&gt;Data _null_ ;&lt;BR /&gt;&amp;nbsp; x = sleep(8);&lt;BR /&gt;&amp;nbsp; run;&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;/* load template */&lt;BR /&gt;&lt;BR /&gt;%sysexec "C:\temp\weekly_00000000.xls";&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;filename excelsys DDE 'EXCEL|C:\temp\[weekly_00000000.xls]05 Quarter Performance!R1C6:R21C13' notab lrecl=6000;&lt;BR /&gt;&lt;BR /&gt;libname inpath1 'c:\temp\datasets';&lt;BR /&gt;&lt;BR /&gt;Data _null_ ;&lt;BR /&gt;&amp;nbsp; file excelsys ;&lt;BR /&gt;&amp;nbsp; set&amp;nbsp; inpath1.filein ;&lt;BR /&gt;&amp;nbsp; put &amp;nbsp;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '09'x &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '09'x&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '09'x&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '09'x &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var5&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '09'x&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var6&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '09'x&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var7 &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; run;&lt;BR /&gt;filename cmds dde 'excel|system' ;&lt;BR /&gt;data _null_ ;&lt;BR /&gt;&amp;nbsp; file cmds; ;&lt;BR /&gt;&amp;nbsp; put '[SELECT("R1C6:R21C13")]';&lt;BR /&gt;&amp;nbsp; put '[SAVE.AS("C:\temp\weekly_20160331.xls")]'; ;&lt;BR /&gt;&amp;nbsp;* put '[QUIT()]';&lt;BR /&gt;&amp;nbsp; run;&lt;BR /&gt;&lt;BR /&gt;filename excelsys clear;&lt;/P&gt;
&lt;P&gt;------------------------------------------------------------------------------------------------------------&lt;/P&gt;
&lt;P&gt;PS: this is one of worksheets that user request to add in for a report of 15 worksheets.&lt;/P&gt;
&lt;P&gt;The old code is so complex that I just want to replace my new code. If there is no way, I need to investigate the old code to put my code in.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 13:04:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263854#M15630</guid>
      <dc:creator>wtien196838</dc:creator>
      <dc:date>2016-04-14T13:04:03Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263920#M15632</link>
      <description>&lt;P&gt;If you already have the file open, your last file name statement should be ONLY sheet and cell reference, not the full path again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Again, see the paper pg 2 for an example.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 16:25:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263920#M15632</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-04-14T16:25:47Z</dc:date>
    </item>
    <item>
      <title>Re: Export SAS dataset with DDE: Excel file with worksheet name issue</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263979#M15634</link>
      <description>&lt;P&gt;Thank you for all helpful suggestions.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Reeza suggested me a hint: remove the path of excel output file (in filename). Then sas export data output correctly into cell range and into correct tabname (with space).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Again thanks for all contributors.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;William&lt;/P&gt;</description>
      <pubDate>Thu, 14 Apr 2016 19:11:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Export-SAS-dataset-with-DDE-Excel-file-with-worksheet-name-issue/m-p/263979#M15634</guid>
      <dc:creator>wtien196838</dc:creator>
      <dc:date>2016-04-14T19:11:19Z</dc:date>
    </item>
  </channel>
</rss>

