<?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: Exporting from SAS to Excel Worksheet without overwriting formatting and tables in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690054#M209852</link>
    <description>&lt;P&gt;If the purpose of all this is to create a pdf document from SAS data, you can do that in SAS and avoid the Excel detour.&lt;/P&gt;</description>
    <pubDate>Thu, 08 Oct 2020 15:35:40 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2020-10-08T15:35:40Z</dc:date>
    <item>
      <title>Exporting from SAS to Excel Worksheet without overwriting formatting and tables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690028#M209839</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I currently export from SAS to excel with a proc export procedure.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;PROC EXPORT DATA=msrflow.msrflow_batch_totals
outfile= &amp;amp;exportoutfiletot
dbms=xlsx replace;
sheet="DLY_BATCH_TOTALS";
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Right now it works as intended.&amp;nbsp; The udpated data replaces the sheet that is in the current workbook.&amp;nbsp; In the actual excel file I am trying to create dynamic pivot tables on a separate sheet that will auto update when the data in the sheet is updated from SAS.&amp;nbsp; I have not found a great way to do this dynamically.&amp;nbsp; I was trying to format the data that is updated as a table in excel so the pivot tables would dynamically update, however, each time I export fresh data from SAS, the formatted table of the data is overwritten with just the raw data.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My ultimate question here is how can I export the data so all of my pivot tables will work correctly with updated data from the sheet I am exporting to?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 08 Oct 2020 14:59:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690028#M209839</guid>
      <dc:creator>elwayfan446</dc:creator>
      <dc:date>2020-10-08T14:59:01Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting from SAS to Excel Worksheet without overwriting formatting and tables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690041#M209845</link>
      <description>&lt;P&gt;If you're on Windows then the following macro might be what you need:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/FriedEgg/Papers/tree/master/Excelling_to_Another_Level_with_SAS/doc" target="_blank"&gt;https://github.com/FriedEgg/Papers/tree/master/Excelling_to_Another_Level_with_SAS/doc&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;HTH,&lt;/P&gt;
&lt;P&gt;Art&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 08 Oct 2020 15:14:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690041#M209845</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2020-10-08T15:14:07Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting from SAS to Excel Worksheet without overwriting formatting and tables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690052#M209851</link>
      <description>Without reading through this in depth, is this a completely hands off approach? Everything is automated in my process right now. The scheduler runs a process flow in Enterprise Guide (which kicks off a program with the proc export above). Then the worksheet is downloaded to the network.&lt;BR /&gt;&lt;BR /&gt;I have a power shell script that opens the workbook and prints the first sheet as a pdf and saves it to another location.  The problem is that once the power shell opens the workbook and it’s refreshed, none of the pivot tables on that first sheet are updated because the new data in the sheets it is coming from has been over written with the new data from the export.&lt;BR /&gt;&lt;BR /&gt;Clear as mud? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 08 Oct 2020 15:29:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690052#M209851</guid>
      <dc:creator>elwayfan446</dc:creator>
      <dc:date>2020-10-08T15:29:13Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting from SAS to Excel Worksheet without overwriting formatting and tables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690054#M209852</link>
      <description>&lt;P&gt;If the purpose of all this is to create a pdf document from SAS data, you can do that in SAS and avoid the Excel detour.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Oct 2020 15:35:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690054#M209852</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2020-10-08T15:35:40Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting from SAS to Excel Worksheet without overwriting formatting and tables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690058#M209855</link>
      <description>Yes. There is much more formatting flexibility within excel than the options in Enterprise Guide that I’ve found. If there is something better in EG I’m missing then that would we great.&lt;BR /&gt;</description>
      <pubDate>Thu, 08 Oct 2020 15:39:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690058#M209855</guid>
      <dc:creator>elwayfan446</dc:creator>
      <dc:date>2020-10-08T15:39:13Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting from SAS to Excel Worksheet without overwriting formatting and tables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690065#M209859</link>
      <description>&lt;P&gt;I don't think the macro will work with Enterprise Guide. If you have access to a copy of SAS, on either a Windows-based machine or Windows-based server, the macro would do what you want. It's intended to submit code, like your proc export code, but that uses vb script to (1) copy and paste your data to a range that you specify (i.e., not a predefined range); (2) not alter existing formats; and/or (3) use an existing workbook or template as a template to paste data into a range.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes, it can be run as a totally hands-off approach.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 08 Oct 2020 15:49:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Exporting-from-SAS-to-Excel-Worksheet-without-overwriting/m-p/690065#M209859</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2020-10-08T15:49:51Z</dc:date>
    </item>
  </channel>
</rss>

