Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

robert_dolezych
Not applicable

How to export a table using macro embeded in the script

Hallo Community!

What is wrong with the process?

Macro:

Function ExTB()
dim ex
set ex = ActiveDocument.GetSheetObject("TB01")
ex.ExportHTML "C:\EntwicklungTests\TB01.html"
end Function

Script:

LOAD DRG_Code, DRG_Typ, DRG_Bezeichnung, DRG_Partition
FROM (qvd);
let ExTB = ExTB();


I am not getting an error message, but it does not work.


I have tried somthing like follows too:

Macro:
Sub TBex
set ex = ActiveDocument.GetSheetObject("TB01")
ex.ExportBiff "C:\EntwicklungTests\TB01.xls"
end Sub

Script:
LOAD
DRG_Code, DRG_Typ, DRG_Bezeichnung, DRG_Partition
FROM (qvd);

call TBex();

Than I am getting the message:
Fehler in Skriptzeile: (error in the script line)

call TBex()

I am perplexed because the both macros are working perfectly, when testing in the macro editor and I suppose the question is solved many times but I did not find the right thread.

1 Solution

Accepted Solutions
robert_dolezych
Not applicable

Re: How to export a table using macro embeded in the script

What helps mostly is reading. I have found everything in the QV help file.

The solution is not in the script!

Settings → Document Properties → Triggers …

1 Reply
robert_dolezych
Not applicable

Re: How to export a table using macro embeded in the script

What helps mostly is reading. I have found everything in the QV help file.

The solution is not in the script!

Settings → Document Properties → Triggers …