Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Export Macro doesn't work when linked to a button

I am running Qlikview 9 SR5 (64 Bit)

I have created a macro to export a table to an excel file into the file system. When I hit the test button in the editor the macro runs fine and the file is created in the file system. However when I try to run the same macro by hitting a button on the qlikview screen nothing works. I don't get any messages to indicate where it may be failing. the button has Action=Run Macro with the correct code as macro.

I have set the macro security to allow system access plus its local security as system access. Plus I set the enable condition=1 in case that was the problem.

the macro is as follows;





sub Exports
set Table = ActiveDocument.GetSheetObject("TB01")
rem Clear all selections that was made
ActiveDocument.ClearAll false

rem Get data in TB01
ActiveDocument.Fields("WO Status").Select("In Progress")
set obj = ActiveDocument.GetSheetObject("TB01")

rem Save data from table in file.
obj.ExportBiff "d:\TimeSheetWO\Work_Order_Dump.xls"
End Sub

I have tried running the macro from the Qlikview program and using the IE plugin but the result is the same. It doesn't appear to run. I am new to Qlikview so I apologise if my post is not clear enough.

0 Replies