title: How to Declare Global Array Variable in SAS?
body: <p>I'm new to SAS and spinning my wheels. The SAS documentation and other Google searches have not helped me figure this out. How can I declare a global array variable that I can use in various procedures to loop through the contents?</p>
  
  <p>Here is what I've tried:</p>
  
  <pre><code>%let fileArray = array{*} $32 file1-file4  ('ce_abcdef_filedetail1' 'ce_abcdef_filedetail2' 'ce_abcdef_filedetail3' 'ce_abcdef_filedetail4' );
  
  /* Loop through each file and run the macro*/
  do i = 1 to dim(fileArray);
       %analyze_file(FILENAME=&amp;fileArray[i], PATH=&amp;path, OUTPUT=&amp;output)
  end;
  </code></pre>
  
  <p>I need it to pass the filename that I specify in the global array.
  Thanks for any help!</p>