Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Export PDF

Hi all,

this is my macro:

sub printRP01

printReportPDF "C:\Users\Public\Documents\TestQlik\PreviousPeek\Test\18T.pdf"

ActiveDocument.GetApplication.Sleep 2000

ActiveDocument.PrintReport "RP02", "QlikviewPDF"

ActiveDocument.GetApplication.Sleep 10000

end sub

'===========================================================================

Function printReportPDF(pdfOutputFile)

Set WSHShell = CreateObject("WScript.Shell")

WSHShell.RegWrite "HKCU\Software\QlikviewPDF\OutputFile", pdfOutputFile, "REG_SZ"

WSHShell.RegWrite "HKCU\Software\QlikviewPDF\BypassSaveAs", "1", "REG_SZ"

Set WSHShell = nothing

End function

at the second line (printReportPDF "C:\Users\Public\Documents\TestQlik\PreviousPeek\Test\18T.pdf") i've this error:

ActiveX component can't create object: 'WScript.Shell'

I use QlikView 10 SR2 64bit and i've installed PDFCreator 1.2.1

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Are you allowing System Access for your macros?

View solution in original post

4 Replies
Anonymous
Not applicable
Author

Are you allowing System Access for your macros?

Not applicable
Author

thx Johannes! How you suggest i allowed System Access for macros with ctrl+shift+M and now it works... but files pdf aren't store in directory. I check and the path where i want to save exists on my machine. I set even the UAC (User Access Control) on my windows 7.

Another question is how i can automate in qlik System Access for macros, because when i close and then restart qlik i have to allow System Access again.

Not applicable
Author

thks, for the Ctrl+Shift+M cause I give permisions into the macro, bút into the script

Not applicable
Author

hi s.fiemazzo

i tested your example. and all the same i tested, stop at this line, and no error info bake to me

ActiveDocument.PrintReport "reportID", "QlikviewPDF",false

is there any thing i need set before?