<?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: SAS export multiple sheet to EXCEL and Replace the whole file in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SAS-export-multiple-sheet-to-EXCEL-and-Replace-the-whole-file/m-p/421401#M280795</link>
    <description>&lt;P&gt;FDELETE() function.&lt;/P&gt;</description>
    <pubDate>Thu, 14 Dec 2017 22:54:10 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2017-12-14T22:54:10Z</dc:date>
    <item>
      <title>SAS export multiple sheet to EXCEL and Replace the whole file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-export-multiple-sheet-to-EXCEL-and-Replace-the-whole-file/m-p/421400#M280794</link>
      <description>&lt;P&gt;Hi Everyone,&lt;/P&gt;
&lt;P&gt;I export multiple sheets to 1 excel file like below.&lt;/P&gt;
&lt;P&gt;I wonder when I redo my work, how can I delete the whole old Excel file.&lt;/P&gt;
&lt;P&gt;Thank you for your help.&lt;/P&gt;
&lt;P&gt;HC&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*First Export , 2 sheets;

proc export data=sashelp.class (where=(age=11))
             outfile="C:\Users\hoang.nguyen\Documents\sas temp\multi.xlsx"
dbms=xlsx    replace ;
   sheet="Monday";run;

proc export data=sashelp.class(where=(age=12))
             outfile="C:\Users\hoang.nguyen\Documents\sas temp\multi.xlsx"
             dbms=xlsx replace ;
   sheet="Tuesday";run;

*Second Export --&amp;gt; How can I delete the old file
This code below only add new sheet to the old file;
proc export data=sashelp.cars 
             outfile="C:\Users\hoang.nguyen\Documents\sas temp\multi.xlsx"
dbms=xlsx    replace ;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 14 Dec 2017 22:47:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-export-multiple-sheet-to-EXCEL-and-Replace-the-whole-file/m-p/421400#M280794</guid>
      <dc:creator>hhchenfx</dc:creator>
      <dc:date>2017-12-14T22:47:16Z</dc:date>
    </item>
    <item>
      <title>Re: SAS export multiple sheet to EXCEL and Replace the whole file</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-export-multiple-sheet-to-EXCEL-and-Replace-the-whole-file/m-p/421401#M280795</link>
      <description>&lt;P&gt;FDELETE() function.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Dec 2017 22:54:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-export-multiple-sheet-to-EXCEL-and-Replace-the-whole-file/m-p/421401#M280795</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2017-12-14T22:54:10Z</dc:date>
    </item>
  </channel>
</rss>

