<?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: Qv.exe /r non interactive (avoid dialogs) in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279560#M104034</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It might be seen as rather dangerous to use ErrorMode but hanging up and waiting for a response and stopping other reloads is arguably even worse!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is possible to make it less so though.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have spreadsheets that contain the email address of the developer(s) and also of the key user/administrators of the document. When the document is reloaded in batch (using the /r switch) I also pass the named pair of a variable VRELOAD so I can detect this in the script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the code - note the comments re the alerts (jpeg attached) and OnPostReload actions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vDocumentName = capitalize(trim(replace(upper(DocumentName()), '.QVW', ' ')));&lt;BR /&gt;SET vRelPath = '..\'; // path to server folders&lt;BR /&gt;SET vUserPath = 'J:\pathname\'; // path to user maintained folders&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// If any errors in batch reload then ignore them and let the script finish - as ScriptErrorCount &amp;lt;&amp;gt; 0 an alert will fire&lt;BR /&gt;// to email the developers. A separate alert fires to email the (data) administrators confirming the reload and the counts&lt;BR /&gt;// of script and other errors.&lt;BR /&gt;// Note OnPostReload action (which is always executed even if the script had errors) sets VRELOAD to 0 and ErrorMode to 1&lt;BR /&gt;IF VRELOAD = 1 THEN&lt;/P&gt;&lt;P&gt;SET ErrorMode = 0; // batch - ignore any failure and alert is triggered at end&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[tDevelopers]:&lt;BR /&gt;LOAD concat(distinct [Developer Email], ';') as Developers&lt;BR /&gt;FROM $(vRelPath)Developer.xls (biff, embedded labels, table is [$(vDocumentName)$]);&lt;BR /&gt;LET vDevelopers = peek('Developers', 0, 'tDevelopers');&lt;BR /&gt;DROP TABLE [tDevelopers];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[tAdministrators]:&lt;BR /&gt;LOAD concat(distinct [Email address], ';') as Administrators&lt;BR /&gt;FROM $(vUserPath)Distribution Lists.xls (biff, embedded labels, table is [$(vDocumentName)$]);&lt;BR /&gt;LET vAdministrators = peek('Administrators', 0, 'tAdministrators');&lt;BR /&gt;DROP TABLE [tAdministrators];&lt;BR /&gt;&amp;nbsp; &lt;BR /&gt;ELSE&lt;/P&gt;&lt;P&gt;SET ErrorMode = 1; // interactive - halt on any failure&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;END IF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 Feb 2012 10:29:38 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-02-14T10:29:38Z</dc:date>
    <item>
      <title>Qv.exe /r non interactive (avoid dialogs)</title>
      <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279557#M104031</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a w2k8 scheduled&amp;nbsp; task that performs a dashboard synchonization.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The task executes something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;qv.exe /r /nosecurity "c:\mydashboard.qvw"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem comes here. The load script imports data from sources and sometimes these sources can be not available.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What happens? Easy, the reload task remains stalled because of a prompt dialog is displayed and no asnwer is provided. The way to know that this happened is killing the task, opening the dasboard log and executing the reload in a windows session.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My question is: is there any way to reload the dashboard using qv.exe in a 'noninteractive way' in order to avoid any promp dialog?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know that I can avoid any script error....but this is dangerous.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;JOS&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Feb 2012 08:08:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279557#M104031</guid>
      <dc:creator />
      <dc:date>2012-02-14T08:08:20Z</dc:date>
    </item>
    <item>
      <title>Qv.exe /r non interactive (avoid dialogs)</title>
      <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279558#M104032</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; This may or may not work but you can turn off Warnings from within the script, all you need to do is to add:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set ErrorMode =1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Place it after the date format 'Sets' at the start of the script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Search for 'Error Variables' in the Help file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Fingers crossed,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Matt - Visual Analytics Ltd&lt;/P&gt;&lt;P&gt;Qlikview Design Blog: &lt;A href="http://QVDesign.wordpress.com"&gt;http://QVDesign.wordpress.com&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Feb 2012 08:42:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279558#M104032</guid>
      <dc:creator>matt_crowther</dc:creator>
      <dc:date>2012-02-14T08:42:29Z</dc:date>
    </item>
    <item>
      <title>Qv.exe /r non interactive (avoid dialogs)</title>
      <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279559#M104033</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="PadderBetweenControlandBody" style="margin: 0cm 0cm 6pt;"&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #000000; font-size: 12pt; font-family: Calibri;"&gt;Hi Jos,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="margin: 0cm 0cm 10pt;"&gt;&lt;SPAN style="color: #000000; font-size: 12pt; font-family: Calibri;"&gt;The answer is ErrorMode =2, setting ErrorMode will ensure that job exists instead of hanging and waiting user response, when there is failure (non-interactive)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; Have a read of Error Variable...&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="MsoNormal" style="margin: 0cm 0cm 10pt;"&gt;&lt;SPAN style="color: #000000; font-size: 12pt; font-family: Calibri;"&gt;Regards&lt;BR /&gt; Kulbir&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Feb 2012 10:14:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279559#M104033</guid>
      <dc:creator />
      <dc:date>2012-02-14T10:14:06Z</dc:date>
    </item>
    <item>
      <title>Re: Qv.exe /r non interactive (avoid dialogs)</title>
      <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279560#M104034</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It might be seen as rather dangerous to use ErrorMode but hanging up and waiting for a response and stopping other reloads is arguably even worse!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is possible to make it less so though.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have spreadsheets that contain the email address of the developer(s) and also of the key user/administrators of the document. When the document is reloaded in batch (using the /r switch) I also pass the named pair of a variable VRELOAD so I can detect this in the script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the code - note the comments re the alerts (jpeg attached) and OnPostReload actions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vDocumentName = capitalize(trim(replace(upper(DocumentName()), '.QVW', ' ')));&lt;BR /&gt;SET vRelPath = '..\'; // path to server folders&lt;BR /&gt;SET vUserPath = 'J:\pathname\'; // path to user maintained folders&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// If any errors in batch reload then ignore them and let the script finish - as ScriptErrorCount &amp;lt;&amp;gt; 0 an alert will fire&lt;BR /&gt;// to email the developers. A separate alert fires to email the (data) administrators confirming the reload and the counts&lt;BR /&gt;// of script and other errors.&lt;BR /&gt;// Note OnPostReload action (which is always executed even if the script had errors) sets VRELOAD to 0 and ErrorMode to 1&lt;BR /&gt;IF VRELOAD = 1 THEN&lt;/P&gt;&lt;P&gt;SET ErrorMode = 0; // batch - ignore any failure and alert is triggered at end&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[tDevelopers]:&lt;BR /&gt;LOAD concat(distinct [Developer Email], ';') as Developers&lt;BR /&gt;FROM $(vRelPath)Developer.xls (biff, embedded labels, table is [$(vDocumentName)$]);&lt;BR /&gt;LET vDevelopers = peek('Developers', 0, 'tDevelopers');&lt;BR /&gt;DROP TABLE [tDevelopers];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[tAdministrators]:&lt;BR /&gt;LOAD concat(distinct [Email address], ';') as Administrators&lt;BR /&gt;FROM $(vUserPath)Distribution Lists.xls (biff, embedded labels, table is [$(vDocumentName)$]);&lt;BR /&gt;LET vAdministrators = peek('Administrators', 0, 'tAdministrators');&lt;BR /&gt;DROP TABLE [tAdministrators];&lt;BR /&gt;&amp;nbsp; &lt;BR /&gt;ELSE&lt;/P&gt;&lt;P&gt;SET ErrorMode = 1; // interactive - halt on any failure&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;END IF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gordon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Feb 2012 10:29:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279560#M104034</guid>
      <dc:creator />
      <dc:date>2012-02-14T10:29:38Z</dc:date>
    </item>
    <item>
      <title>Qv.exe /r non interactive (avoid dialogs)</title>
      <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279561#M104035</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;set &lt;SPAN style="color: #000000; font-size: 12pt; font-family: Calibri;"&gt;ErrorMode =2 is good enought for me...thanks all you&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Feb 2012 09:27:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279561#M104035</guid>
      <dc:creator />
      <dc:date>2012-02-16T09:27:24Z</dc:date>
    </item>
    <item>
      <title>Qv.exe /r non interactive (avoid dialogs)</title>
      <link>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279562#M104036</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I have the same problem and when I try to run a batch that reload the data&lt;/P&gt;&lt;P&gt;Qv.exe hangs.&lt;/P&gt;&lt;P&gt;Did I set Error Mode inside the load Script ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Oronzo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Mar 2012 09:59:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Qv-exe-r-non-interactive-avoid-dialogs/m-p/279562#M104036</guid>
      <dc:creator />
      <dc:date>2012-03-02T09:59:49Z</dc:date>
    </item>
  </channel>
</rss>

