<?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 Scan function in MACRO in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103300#M21549</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Team,&lt;/P&gt;&lt;P&gt;Recently I learnt that whenever we are refwerring to SAS functions in MAcros we have to use &lt;STRONG&gt;%sysfunc.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In this piece of code ISNT SCAN a SAS function? Don t we need to use &lt;STRONG&gt;%sysfunc before the SCAN.&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%macro&amp;nbsp; dothis;&lt;/P&gt;&lt;P&gt;%let varnames= Apple ball cat orange;&lt;/P&gt;&lt;P&gt;ods pdf file='myfilename';&lt;/P&gt;&lt;P&gt;%do i=1 %to %sysfunc(countw(&amp;amp;varnames));&lt;/P&gt;&lt;P&gt;%let thisvar=%&lt;STRONG&gt;scan&lt;/STRONG&gt;(&amp;amp;varnames,&amp;amp;i, &amp;amp;str());&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 22 Oct 2012 22:56:28 GMT</pubDate>
    <dc:creator>robertrao</dc:creator>
    <dc:date>2012-10-22T22:56:28Z</dc:date>
    <item>
      <title>Scan function in MACRO</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103300#M21549</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Team,&lt;/P&gt;&lt;P&gt;Recently I learnt that whenever we are refwerring to SAS functions in MAcros we have to use &lt;STRONG&gt;%sysfunc.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In this piece of code ISNT SCAN a SAS function? Don t we need to use &lt;STRONG&gt;%sysfunc before the SCAN.&lt;/STRONG&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%macro&amp;nbsp; dothis;&lt;/P&gt;&lt;P&gt;%let varnames= Apple ball cat orange;&lt;/P&gt;&lt;P&gt;ods pdf file='myfilename';&lt;/P&gt;&lt;P&gt;%do i=1 %to %sysfunc(countw(&amp;amp;varnames));&lt;/P&gt;&lt;P&gt;%let thisvar=%&lt;STRONG&gt;scan&lt;/STRONG&gt;(&amp;amp;varnames,&amp;amp;i, &amp;amp;str());&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Oct 2012 22:56:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103300#M21549</guid>
      <dc:creator>robertrao</dc:creator>
      <dc:date>2012-10-22T22:56:28Z</dc:date>
    </item>
    <item>
      <title>Re: Scan function in MACRO</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103301#M21550</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SCAN is a SAS function&lt;/P&gt;&lt;P&gt;%SCAN is a SAS MACRO&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And not all functions work with sysfunc, read the documentation&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/mcrolref/61885/HTML/default/viewer.htm#z3514sysfunc.htm" title="http://support.sas.com/documentation/cdl/en/mcrolref/61885/HTML/default/viewer.htm#z3514sysfunc.htm"&gt;http://support.sas.com/documentation/cdl/en/mcrolref/61885/HTML/default/viewer.htm#z3514sysfunc.htm&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Oct 2012 22:59:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103301#M21550</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2012-10-22T22:59:34Z</dc:date>
    </item>
    <item>
      <title>Re: Scan function in MACRO</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103302#M21551</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;you could if you want to:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%let varnames= Apple ball cat orange;&lt;/P&gt;&lt;P&gt;%let i=1 ;&lt;/P&gt;&lt;P&gt;%let thisvar=%sysfunc(scan(&amp;amp;varnames,&amp;amp;i));&lt;/P&gt;&lt;P&gt;%put &amp;amp;thisvar;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Oct 2012 23:07:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103302#M21551</guid>
      <dc:creator>Linlin</dc:creator>
      <dc:date>2012-10-22T23:07:59Z</dc:date>
    </item>
    <item>
      <title>Re: Scan function in MACRO</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103303#M21552</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yeah,&lt;/P&gt;&lt;P&gt;It works well. So %scan is an inbuilt MAcro function as Reeza was explaining?????&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, 22 Oct 2012 23:14:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Scan-function-in-MACRO/m-p/103303#M21552</guid>
      <dc:creator>robertrao</dc:creator>
      <dc:date>2012-10-22T23:14:31Z</dc:date>
    </item>
  </channel>
</rss>

