<?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: Pasting code from excel to sas in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196266#M49071</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why would you want to be copying code from and Excel file in the first place?&amp;nbsp; Integrated Development Environments and text editors are the tools for coding.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Your problem lies in the fact that Excel has cells, nothing else has this concept.&amp;nbsp; When you copy it takes the text out of those cells, puts a space in between and then keeps it on the clipboard.&amp;nbsp; When you paste this text then gets pasted in the SAS text file.&amp;nbsp; I know that some of the more modern IDEs allow textual alignments to markers (a bit like Word where you can move the ticks at the top and align text to that), but at least up to 9.3 I don't think this was possible.&amp;nbsp; My suggestion - avoid using Excel for anything.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 06 Jul 2015 11:24:46 GMT</pubDate>
    <dc:creator>RW9</dc:creator>
    <dc:date>2015-07-06T11:24:46Z</dc:date>
    <item>
      <title>Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196265#M49070</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm reading in a txt file into sas and write up the fields and attributes in columns in excel and then copy and paste into sas. However, the columns don't line up in sas. Is there a way to paste the data so that it looks like...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;driver_cat&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; $10.;&lt;/P&gt;&lt;P&gt;age&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; $5.;&lt;/P&gt;&lt;P&gt;....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;driver_cat $10.;&lt;/P&gt;&lt;P&gt;age&amp;nbsp; $5.;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 11:18:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196265#M49070</guid>
      <dc:creator>brophymj</dc:creator>
      <dc:date>2015-07-06T11:18:03Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196266#M49071</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why would you want to be copying code from and Excel file in the first place?&amp;nbsp; Integrated Development Environments and text editors are the tools for coding.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Your problem lies in the fact that Excel has cells, nothing else has this concept.&amp;nbsp; When you copy it takes the text out of those cells, puts a space in between and then keeps it on the clipboard.&amp;nbsp; When you paste this text then gets pasted in the SAS text file.&amp;nbsp; I know that some of the more modern IDEs allow textual alignments to markers (a bit like Word where you can move the ticks at the top and align text to that), but at least up to 9.3 I don't think this was possible.&amp;nbsp; My suggestion - avoid using Excel for anything.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 11:24:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196266#M49071</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2015-07-06T11:24:46Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196267#M49072</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are there text editor tools in SAS?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 11:28:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196267#M49072</guid>
      <dc:creator>brophymj</dc:creator>
      <dc:date>2015-07-06T11:28:26Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196268#M49073</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you are using SAS University Edition, there is a tool button named 'Formate code' to make your code readable .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 11:50:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196268#M49073</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2015-07-06T11:50:08Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196269#M49074</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have sas 9.3 - is there something there where you can just paste a columns of fields and then another columns of attributes in such a way that they are aligned.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 12:34:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196269#M49074</guid>
      <dc:creator>brophymj</dc:creator>
      <dc:date>2015-07-06T12:34:21Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196270#M49075</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There is the Enhanced Editor and basic Editor.&amp;nbsp; Neither of which has alignment controls other than to put spaces instead of tabs.&amp;nbsp; What are you trying to do though?&amp;nbsp; If its just a parameter list, put it in a text file and %include or infile it in, doesn't seem to be much point in copy/pasting it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 13:07:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196270#M49075</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2015-07-06T13:07:59Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196271#M49076</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;EG also has a format your code option. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TWo other things to try:&lt;/P&gt;&lt;P&gt;1. Cut and paste each column using ALT key. I think this works but not in front of SAS to try. &lt;/P&gt;&lt;P&gt;2 Create the appropriate text in Excel using Concatenate and length functions before pasting to SAS. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 13:50:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196271#M49076</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-07-06T13:50:54Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196272#M49077</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Import the Excel file into SAS, and then use formatted output to write a file with the correct spacings. You can then copy/paste from there.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 13:54:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196272#M49077</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2015-07-06T13:54:08Z</dc:date>
    </item>
    <item>
      <title>Re: Pasting code from excel to sas</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196273#M49078</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Whenever I need to do this, I do it in Excel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Assuming that my variable name is in cell A1, and my length in B1, the formula&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=MID(A1&amp;amp;REPT(" ",20),1,20)&amp;amp;B1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;should give you attractive output. Substitute whichever number looks good for the two instances of 20.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 16:09:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Pasting-code-from-excel-to-sas/m-p/196273#M49078</guid>
      <dc:creator>TomKari</dc:creator>
      <dc:date>2015-07-06T16:09:15Z</dc:date>
    </item>
  </channel>
</rss>

