<?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 pdf print macro not working in Access Point in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408373#M151892</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 am struggling with a pdf printer macro and I need your wish help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a macro in qlikview that prints Invoices, it creates one pdf file per invoice. The invoice layout is defined as a Report and this report is printed once per Invoice. Y&lt;SPAN style="font-size: 10pt;"&gt;ou can find my code below.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This code works in local, with the qlikview developer tool, but when I test it in the access point (in the same machine). it doesn't.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a button that launches the macro when I click on it. I tested that the macro runs in access point. It actually does since I see how it execute the rest of the code but the print to pdf.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody please help me with this, please? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sub printRepPDF3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set invoiceField=ActiveDocument.Fields("DocumentTable.DocNum")&lt;/P&gt;&lt;P&gt;Set invoiceValues=invoiceField.GetPossibleValues&lt;/P&gt;&lt;P&gt;numInvoices=invoiceValues.Count&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If numInvoices&amp;gt;0 then&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for i=0 to numInvoices-1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;vCurrentInvoice=invoiceValues.Item(i).text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;invoiceField.Select vCurrentInvoice&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;fileName="C:\Invoices\Invoice" &amp;amp; vCurrentInvoice &amp;amp;".pdf"&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ActiveDocument.GetApplication.Sleep 2000&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;STRONG&gt;ActiveDocument.PrintReport "RP02", "PDF-XChange 3.0", false&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; Set objFSO = CreateObject("Scripting.FileSystemObject")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;objFSO.MoveFile "C:\Invoices\pdf xchange file.pdf", fileName&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ActiveDocument.GetApplication.Sleep 2000&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;Next&lt;/P&gt;&lt;P&gt;ActiveDocument.GetApplication.Sleep 10000&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;end sub&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 05 Mar 2013 11:31:28 GMT</pubDate>
    <dc:creator />
    <dc:date>2013-03-05T11:31:28Z</dc:date>
    <item>
      <title>pdf print macro not working in Access Point</title>
      <link>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408373#M151892</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 am struggling with a pdf printer macro and I need your wish help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a macro in qlikview that prints Invoices, it creates one pdf file per invoice. The invoice layout is defined as a Report and this report is printed once per Invoice. Y&lt;SPAN style="font-size: 10pt;"&gt;ou can find my code below.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This code works in local, with the qlikview developer tool, but when I test it in the access point (in the same machine). it doesn't.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a button that launches the macro when I click on it. I tested that the macro runs in access point. It actually does since I see how it execute the rest of the code but the print to pdf.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody please help me with this, please? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sub printRepPDF3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set invoiceField=ActiveDocument.Fields("DocumentTable.DocNum")&lt;/P&gt;&lt;P&gt;Set invoiceValues=invoiceField.GetPossibleValues&lt;/P&gt;&lt;P&gt;numInvoices=invoiceValues.Count&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If numInvoices&amp;gt;0 then&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for i=0 to numInvoices-1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;vCurrentInvoice=invoiceValues.Item(i).text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;invoiceField.Select vCurrentInvoice&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;fileName="C:\Invoices\Invoice" &amp;amp; vCurrentInvoice &amp;amp;".pdf"&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ActiveDocument.GetApplication.Sleep 2000&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;STRONG&gt;ActiveDocument.PrintReport "RP02", "PDF-XChange 3.0", false&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; Set objFSO = CreateObject("Scripting.FileSystemObject")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;objFSO.MoveFile "C:\Invoices\pdf xchange file.pdf", fileName&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ActiveDocument.GetApplication.Sleep 2000&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;Next&lt;/P&gt;&lt;P&gt;ActiveDocument.GetApplication.Sleep 10000&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;end sub&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Mar 2013 11:31:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408373#M151892</guid>
      <dc:creator />
      <dc:date>2013-03-05T11:31:28Z</dc:date>
    </item>
    <item>
      <title>Re: pdf print macro not working in Access Point</title>
      <link>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408374#M151893</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think I found the answer: Basically, I needed to habilitate the ie plugin in the server. Once I did that, it worked from access point through the server. Also, I tried from a remote computer, downloading and installing the plugin and it works like a charm.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To accomplish that I followed this topic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" class="loading" href="https://community.qlik.com/thread/63999" title="http://community.qlik.com/thread/63999"&gt;http://community.qlik.com/thread/63999&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Julian&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Mar 2013 13:43:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408374#M151893</guid>
      <dc:creator />
      <dc:date>2013-03-05T13:43:46Z</dc:date>
    </item>
    <item>
      <title>Re: pdf print macro not working in Access Point</title>
      <link>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408375#M151894</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;glad you have foud your answer on &lt;A href="http://www.rasteredge.com/how-to/vb-net-imaging/pdf-print/"&gt;pdf printer&lt;/A&gt;, can you share with use. i was having the same problem. thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jul 2013 10:21:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408375#M151894</guid>
      <dc:creator />
      <dc:date>2013-07-22T10:21:07Z</dc:date>
    </item>
    <item>
      <title>Re: pdf print macro not working in Access Point</title>
      <link>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408376#M151895</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The vba macro written above works for PDF-Xchange 3.0, I changed my code to use another pdf printer, in this case PDFCreator because it is free. This would be the code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In my application I print invoices based on customer selected. It prints one PDF per invoice. RP02 is the name of the table that I print&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sub printRepPDFCreator&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;'I get the values for invoices and for customers here.&lt;/P&gt;&lt;P&gt;Set invoiceField=ActiveDocument.Fields("DistributorOrders.DistributorOrderHeaderID")&lt;/P&gt;&lt;P&gt;Set invoiceValues=invoiceField.GetPossibleValues&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Set customerField=ActiveDocument.Fields("DistributorOrders.SAP_CustomerName")&lt;/P&gt;&lt;P&gt;Set customerValues=customerField.GetPossibleValues&lt;/P&gt;&lt;P&gt;numInvoices=invoiceValues.Count&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If numInvoices&amp;gt;0 then&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for i=0 to numInvoices-1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; vCurrentInvoice=invoiceValues.Item(i).text&lt;/P&gt;&lt;P&gt;&amp;nbsp; invoiceField.Select vCurrentInvoice&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Set customerField=ActiveDocument.Fields("DistributorOrders.SAP_CustomerName")&lt;/P&gt;&lt;P&gt;&amp;nbsp; Set customerValues=customerField.GetPossibleValues&lt;/P&gt;&lt;P&gt;&amp;nbsp; vCurrentCustomer=customerValues.Item(0).text&lt;/P&gt;&lt;P&gt; &lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Print_PDF vCurrentInvoice, vCurrentCustomer &amp;amp; " Order", "RP02"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Next&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;'This will show a message indicating when it has finished&lt;/P&gt;&lt;P&gt;ActiveDocument.GetApplication.MsgBox("Export Completed ! ")&lt;/P&gt;&lt;P&gt;end sub&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Oct 2013 10:35:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/pdf-print-macro-not-working-in-Access-Point/m-p/408376#M151895</guid>
      <dc:creator />
      <dc:date>2013-10-15T10:35:16Z</dc:date>
    </item>
  </channel>
</rss>

