<?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 VBScript automation - errors, arrays and monitoring in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864489#M42559</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm in the process of creating an automation script for the daily SAS reports and I have some key issues that I'd really appreciate assistance with.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Error checking / reporting&lt;/U&gt;&lt;/P&gt;&lt;P&gt;So I have an array of projects:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;prjPaths = Array("Report1.egp","Report2.egp".... )&lt;/STRONG&gt; and so on.&lt;/P&gt;&lt;P&gt;Currently there are 17 as a proof of concept but this will double when I have ironed out the issues. I loop through this array with:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;For Each prjName in prjPaths&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;which is working fine, however we have quite a temperamental environment / VPN. So what I'm trying to achieve is to log in a simple manner whether a workflow has run without errors (warnings I don't mind). Any ideas on how to write this for each report to a file?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Array gathering&lt;/U&gt;&lt;/P&gt;&lt;P&gt;All these Report.egp are in different folders and may be modified / updated to new versions by any member of the team. I built a vbscript to create a text array by searching for EGP files in locations, but when I include this and use the "strText" in the above&amp;nbsp;&lt;STRONG&gt;prjPaths = Array("strText") &lt;/STRONG&gt;it doesn't work, but if I write this to a file it's exactly how I've manually put the list into the array. Again, any ideas?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Monitoring&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Last one I promise!&amp;nbsp;&lt;/P&gt;&lt;P&gt;When you run a script for SAS it runs in the background and you can see in the task manager that something is running but not which. I have a MsgBox at the end to tell me that it's all run, but it would be great to see that it's currently running or even better, which part of the array is currently running.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for any and all help!&lt;/P&gt;</description>
    <pubDate>Thu, 16 Mar 2023 11:55:34 GMT</pubDate>
    <dc:creator>Seb_A_Sanders</dc:creator>
    <dc:date>2023-03-16T11:55:34Z</dc:date>
    <item>
      <title>VBScript automation - errors, arrays and monitoring</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864489#M42559</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm in the process of creating an automation script for the daily SAS reports and I have some key issues that I'd really appreciate assistance with.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Error checking / reporting&lt;/U&gt;&lt;/P&gt;&lt;P&gt;So I have an array of projects:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;prjPaths = Array("Report1.egp","Report2.egp".... )&lt;/STRONG&gt; and so on.&lt;/P&gt;&lt;P&gt;Currently there are 17 as a proof of concept but this will double when I have ironed out the issues. I loop through this array with:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;For Each prjName in prjPaths&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;which is working fine, however we have quite a temperamental environment / VPN. So what I'm trying to achieve is to log in a simple manner whether a workflow has run without errors (warnings I don't mind). Any ideas on how to write this for each report to a file?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Array gathering&lt;/U&gt;&lt;/P&gt;&lt;P&gt;All these Report.egp are in different folders and may be modified / updated to new versions by any member of the team. I built a vbscript to create a text array by searching for EGP files in locations, but when I include this and use the "strText" in the above&amp;nbsp;&lt;STRONG&gt;prjPaths = Array("strText") &lt;/STRONG&gt;it doesn't work, but if I write this to a file it's exactly how I've manually put the list into the array. Again, any ideas?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Monitoring&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Last one I promise!&amp;nbsp;&lt;/P&gt;&lt;P&gt;When you run a script for SAS it runs in the background and you can see in the task manager that something is running but not which. I have a MsgBox at the end to tell me that it's all run, but it would be great to see that it's currently running or even better, which part of the array is currently running.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for any and all help!&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 11:55:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864489#M42559</guid>
      <dc:creator>Seb_A_Sanders</dc:creator>
      <dc:date>2023-03-16T11:55:34Z</dc:date>
    </item>
    <item>
      <title>Re: VBScript automation - errors, arrays and monitoring</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864544#M42562</link>
      <description>&lt;P&gt;As stated on here before, run PowerShell vs VBScript. There are plenty of examples on using PowerShell and SAS. See if that clears up a number of your questions.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Start there. I wouldn't spend another minute in VBScript.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 14:08:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864544#M42562</guid>
      <dc:creator>AlanC</dc:creator>
      <dc:date>2023-03-16T14:08:04Z</dc:date>
    </item>
    <item>
      <title>Re: VBScript automation - errors, arrays and monitoring</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864550#M42563</link>
      <description>&lt;P&gt;Seems like you two main issues resolve around the VBscript part. So probably should ask on a VBscript forum, especially since you do not actually include any of the SAS portion.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might describe your SAS environment. Depending on specifics of what the "automation script" is supposed to do there may be tools in SAS that does what is needed.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 14:25:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/VBScript-automation-errors-arrays-and-monitoring/m-p/864550#M42563</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2023-03-16T14:25:31Z</dc:date>
    </item>
  </channel>
</rss>

