<?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 SAS Studio - Writing to a named range in Excel in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631538#M20949</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm a bit puzzled and hoping someone can shed some light on what's causing this issue. I was recently introduced by a colleague at work to the idea of writing data to an Excel sheet using a named range (already existing on the Excel book, but deleted using proc datasets then written again in a data step). I have done this successfully in EG as follows: -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%let xlpath=########/Arrears Level Charts.xlsx;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;libname xl Excel "&amp;amp;xlpath";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc datasets lib=xl nolist;&lt;BR /&gt;delete arrs_level.;&lt;BR /&gt;quit;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data xl.arrs_level.;&lt;BR /&gt;set arrs_level._trans_2;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;libname xl clear;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have tried to use the same concept in SAS Studio but rather than the data being written to the named range on an existing tab, it is creating a new tab in the workbook with the named range name as the tab name, and creating the named range in that sheet. The only difference in the coding is that I have had to use the xlsx engine rather than the Excel one in my libname statement. Is anyone able to suggest why this might be happening, and what I would need to do to get the data written to the existing named range?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance for any suggestions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;</description>
    <pubDate>Thu, 12 Mar 2020 12:47:24 GMT</pubDate>
    <dc:creator>robulon</dc:creator>
    <dc:date>2020-03-12T12:47:24Z</dc:date>
    <item>
      <title>SAS Studio - Writing to a named range in Excel</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631538#M20949</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm a bit puzzled and hoping someone can shed some light on what's causing this issue. I was recently introduced by a colleague at work to the idea of writing data to an Excel sheet using a named range (already existing on the Excel book, but deleted using proc datasets then written again in a data step). I have done this successfully in EG as follows: -&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%let xlpath=########/Arrears Level Charts.xlsx;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;libname xl Excel "&amp;amp;xlpath";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc datasets lib=xl nolist;&lt;BR /&gt;delete arrs_level.;&lt;BR /&gt;quit;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data xl.arrs_level.;&lt;BR /&gt;set arrs_level._trans_2;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;libname xl clear;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have tried to use the same concept in SAS Studio but rather than the data being written to the named range on an existing tab, it is creating a new tab in the workbook with the named range name as the tab name, and creating the named range in that sheet. The only difference in the coding is that I have had to use the xlsx engine rather than the Excel one in my libname statement. Is anyone able to suggest why this might be happening, and what I would need to do to get the data written to the existing named range?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance for any suggestions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;</description>
      <pubDate>Thu, 12 Mar 2020 12:47:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631538#M20949</guid>
      <dc:creator>robulon</dc:creator>
      <dc:date>2020-03-12T12:47:24Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Studio - Writing to a named range in Excel</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631602#M20958</link>
      <description>The engines work differently. I've found PCFILES and Excel work, but not the newer one sadly. &lt;BR /&gt;&lt;BR /&gt;Fortunately ODS EXCEL is coming along.</description>
      <pubDate>Thu, 12 Mar 2020 15:18:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631602#M20958</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-03-12T15:18:58Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Studio - Writing to a named range in Excel</title>
      <link>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631798#M20992</link>
      <description>&lt;P&gt;Thanks Reeza,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It's no biggie as I've already got something in place that does what I need to do (I'm just proc exporting to a different tab, then using formulas to pull the data in to where I was hoping I could write the named range to).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was just interested as to whether I was missing something fundamental.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;</description>
      <pubDate>Fri, 13 Mar 2020 08:13:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/SAS-Studio-Writing-to-a-named-range-in-Excel/m-p/631798#M20992</guid>
      <dc:creator>robulon</dc:creator>
      <dc:date>2020-03-13T08:13:29Z</dc:date>
    </item>
  </channel>
</rss>

