Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Print PDF macro using Adobe Acrobate Pro 9

Hello All,

Please help with the Print PDF macro using Adobe Acrobate Pro 9.

In QV9  server  we were using PDF creator to print PDF report. Now we have migrated to qv 11.2 and infra team is not able to install pdfcreator in qv 11 environment.

Looking for your help.

Thanks & Regards,

D

2 Replies
Not applicable
Author

Hi, Dixit.

I am not using Adobe Acrobate Pro 9. But I am testing about another PDF creator to print PDF report. I want to look for a fine tool whose way of processing is simple and fast to help me with the related PDF work.  It will be better if it is totally manual and can be customized by users according to our own favors. Do you have any ideas about it? Or any good suggestion? Thanks in advance. And I hope you success. Good luck.

Best regards,

Arron

Not applicable
Author

What exactly you are trying to do with PDF creator? and what do you meant by customized by users according to our own ..?

For PDF creator I have used following macro to automate reports.

Sub Print_PDF(ReportName, ReportID)

    Dim pdfjob

    Dim sPDFName

    Dim sPDFPath

    sPDFName = ReportName

    sPDFPath = "C:\Documents and Settings\xxxxxxxx\Desktop\xxxxx\xxxxx"  ' PDF report save path

    Set pdfjob = CreateObject("PDFCreator.clsPDFCreator")

    With pdfjob

      If .cStart("/NoProcessingAtStartup") = False Then

         If .cStart("/NoProcessingAtStartup", True) = False Then

          Exit Sub

         End if

         .cVisible = True

      End If

      .cOption("UseAutosave") = 1

      .cOption("UseAutosaveDirectory") = 1

      .cOption("AutosaveDirectory") = sPDFPath

      .cOption("AutosaveFilename") = sPDFName

      .cOption("AutosaveFormat") = 0 ' 0 = PDF

      .cClearCache

    End With

  ' Print the  Report

    ActiveDocument.PrintReport ReportID, "PDFCreator"

   'Wait until the print job has entered the print queue

    Do Until pdfjob.cCountOfPrintjobs = 1

     ActiveDocument.GetApplication.Sleep 20

    Loop

    pdfjob.cPrinterStop = False

   'Wait until PDF creator is finished then release the objects

    Do Until pdfjob.cCountOfPrintjobs = 0

     ActiveDocument.GetApplication.Sleep 20

        ' in VBScript use WScript.Sleep(20)

    Loop

    pdfjob.cClose

    Set pdfjob = Nothing

Regards,

D

End Sub