<?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: VBScript Automation API in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858025#M1004456</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I am facing issue to schedule the task as this is running all the time. Please help me with the exact documentation for VBScript-QlikView automation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dim objFSO :&amp;nbsp; Set objFSO = CreateObject("Scripting.FileSystemObject")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set objTextFile = objFSO.OpenTextFile("sLOG.log",8,True)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dim strDocPath : strDocPath= "D:\Qlikview\Scheduler\test1.qvw"&lt;/P&gt;&lt;P&gt;Dim strStoragePath : strStoragePath = "C:\New folder\"&lt;/P&gt;&lt;P&gt;Dim objQV_Application,objActiveDoc,ObjID &lt;/P&gt;&lt;P&gt;Dim strSheetName : strSheetName = "Ra Tracker"&lt;/P&gt;&lt;P&gt;Dim strObjID : strObjID = "TX92"&lt;/P&gt;&lt;P&gt;Dim PicName&amp;nbsp; : PicName = "header.jpg"&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine "::STARTED::"&lt;/P&gt;&lt;P&gt;call Qlik2Shot(strDocPath,strSheetName,strObjID,strStoragePath,PicName)&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine "::COMPLETED::"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub Qlik2Shot(TEMP_DocPath,TEMP_SheetName,TEMP_OBJ,TEMP_ShotPath,TEMP_ShotName)&lt;/P&gt;&lt;P&gt;Dim objQV_Application,objActiveDoc,ObjID &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rem Creating QllikView Application Instance&lt;/P&gt;&lt;P&gt;Set objQV_Application = CreateObject("QlikTech.QlikView")&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;Rem Creating Document Instance&lt;/P&gt;&lt;P&gt;Set objActiveDoc = objQV_Application.OpenDoc(TEMP_DocPath)&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rem Getting the Sheet &lt;/P&gt;&lt;P&gt;objActiveDoc.Sheets(TEMP_SheetName).Activate&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;Rem Setting Object To Be Captured&lt;/P&gt;&lt;P&gt;set ObjID = objActiveDoc.GetSheetObject(TEMP_OBJ)&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;Rem Exporting Bitmap&lt;/P&gt;&lt;P&gt;ObjID.ExportBitmapToFile TEMP_ShotPath &amp;amp; TEMP_ShotName&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rem Closing Objects&lt;/P&gt;&lt;P&gt;Set ObjID = Nothing&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;objActiveDoc.Save&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;WScript.Sleep(250)&lt;/P&gt;&lt;P&gt;Set objActiveDoc = Nothing&lt;/P&gt;&lt;P&gt;objQV_Application.Quit&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;End Sub&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;objActiveDoc.Save&lt;/P&gt;&lt;P&gt;WScript.Sleep(1000)&lt;/P&gt;&lt;P&gt;Set objActiveDoc = Nothing&lt;/P&gt;&lt;P&gt;objQV_Application.Quit&lt;/P&gt;&lt;P&gt;End Sub&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 27 May 2015 13:48:31 GMT</pubDate>
    <dc:creator />
    <dc:date>2015-05-27T13:48:31Z</dc:date>
    <item>
      <title>VBScript Automation API</title>
      <link>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858023#M1004454</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;While trying out the API guide of Qlikview 11 at &lt;A href="https://community.qlik.com/docs/DOC-2640"&gt;QlikView Core COM API Guide - Version 11&lt;/A&gt;. It seems the number of methods do not run. example: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set cs = objActiveDoc.GetSheetObject("TX92")&lt;/P&gt;&lt;P&gt;msgbox(cs.GetNoOfRows)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;as per &lt;A href="https://community.qlik.com/docs/DOC-7940"&gt;Send Mail from QlikView with table in the mail body&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;also, several&amp;nbsp; things are not working properly. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody give a good reference for solving all the VBScript - QlikView Automation. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Saqib&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 May 2015 09:36:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858023#M1004454</guid>
      <dc:creator />
      <dc:date>2015-05-27T09:36:50Z</dc:date>
    </item>
    <item>
      <title>Re: VBScript Automation API</title>
      <link>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858024#M1004455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I came to the same conclusion after testing many of the examples.&lt;/P&gt;&lt;P&gt;Some of them does not work...&lt;/P&gt;&lt;P&gt;But to know why you need to know more about VBS and probably the version of your qlik.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can try to validate them yourself, Google it by looking for VBS course or contact the author.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example you have provide&amp;nbsp; will not work&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Set cs = objActiveDoc.GetSheetObject&lt;STRONG&gt;("TX92")&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;msgbox(cs.GetNoOfRows)&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;TX92&lt;/STRONG&gt; is a textbox which does not have any rows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;do you have any particular problem with macro?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 May 2015 09:49:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858024#M1004455</guid>
      <dc:creator>robert_mika</dc:creator>
      <dc:date>2015-05-27T09:49:15Z</dc:date>
    </item>
    <item>
      <title>Re: VBScript Automation API</title>
      <link>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858025#M1004456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I am facing issue to schedule the task as this is running all the time. Please help me with the exact documentation for VBScript-QlikView automation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dim objFSO :&amp;nbsp; Set objFSO = CreateObject("Scripting.FileSystemObject")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set objTextFile = objFSO.OpenTextFile("sLOG.log",8,True)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dim strDocPath : strDocPath= "D:\Qlikview\Scheduler\test1.qvw"&lt;/P&gt;&lt;P&gt;Dim strStoragePath : strStoragePath = "C:\New folder\"&lt;/P&gt;&lt;P&gt;Dim objQV_Application,objActiveDoc,ObjID &lt;/P&gt;&lt;P&gt;Dim strSheetName : strSheetName = "Ra Tracker"&lt;/P&gt;&lt;P&gt;Dim strObjID : strObjID = "TX92"&lt;/P&gt;&lt;P&gt;Dim PicName&amp;nbsp; : PicName = "header.jpg"&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine "::STARTED::"&lt;/P&gt;&lt;P&gt;call Qlik2Shot(strDocPath,strSheetName,strObjID,strStoragePath,PicName)&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine "::COMPLETED::"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub Qlik2Shot(TEMP_DocPath,TEMP_SheetName,TEMP_OBJ,TEMP_ShotPath,TEMP_ShotName)&lt;/P&gt;&lt;P&gt;Dim objQV_Application,objActiveDoc,ObjID &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rem Creating QllikView Application Instance&lt;/P&gt;&lt;P&gt;Set objQV_Application = CreateObject("QlikTech.QlikView")&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;Rem Creating Document Instance&lt;/P&gt;&lt;P&gt;Set objActiveDoc = objQV_Application.OpenDoc(TEMP_DocPath)&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rem Getting the Sheet &lt;/P&gt;&lt;P&gt;objActiveDoc.Sheets(TEMP_SheetName).Activate&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;Rem Setting Object To Be Captured&lt;/P&gt;&lt;P&gt;set ObjID = objActiveDoc.GetSheetObject(TEMP_OBJ)&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;Rem Exporting Bitmap&lt;/P&gt;&lt;P&gt;ObjID.ExportBitmapToFile TEMP_ShotPath &amp;amp; TEMP_ShotName&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rem Closing Objects&lt;/P&gt;&lt;P&gt;Set ObjID = Nothing&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;objActiveDoc.Save&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;WScript.Sleep(250)&lt;/P&gt;&lt;P&gt;Set objActiveDoc = Nothing&lt;/P&gt;&lt;P&gt;objQV_Application.Quit&lt;/P&gt;&lt;P&gt;If Err.Number&amp;lt;&amp;gt;0 Then&lt;/P&gt;&lt;P&gt;objTextFile.WriteLine Now() &amp;amp; " " &amp;amp; Err.Description &amp;amp; " " &amp;amp;&amp;nbsp; Err.Number &lt;/P&gt;&lt;P&gt;&amp;nbsp; End If &lt;/P&gt;&lt;P&gt;End Sub&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;objActiveDoc.Save&lt;/P&gt;&lt;P&gt;WScript.Sleep(1000)&lt;/P&gt;&lt;P&gt;Set objActiveDoc = Nothing&lt;/P&gt;&lt;P&gt;objQV_Application.Quit&lt;/P&gt;&lt;P&gt;End Sub&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 May 2015 13:48:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/VBScript-Automation-API/m-p/858025#M1004456</guid>
      <dc:creator />
      <dc:date>2015-05-27T13:48:31Z</dc:date>
    </item>
  </channel>
</rss>

