Skip to main content
Announcements
Global Transformation Awards! Applications are now open. Submit Entry
cancel
Showing results for 
Search instead for 
Did you mean: 
jakfourie
Partner - Contributor II
Partner - Contributor II

Automated Export (Macro) to Excel not working in Windows 2016 QV12

Hi,

I am unable to get a macro to run through QMC or Windows Task Scheduler after the server was upgraded to Windows 2016 and QlikView 12. The macro works perfectly when running manually from QlikView Desktop but does not run at all when the qvw is refreshed through QMC or using a batch file and Windows Task Scheduler. Does anybody have any solutions or ideas?

Thanks in advance.

5 Replies
did
Employee
Employee

Hi Jacques,

I had the same problem. As far as I know QMC cannot automatically fire QVW macros. Another problem is: the service user (running automatically) can neither user Excel.Application nor simulate it - that is why any vbs batch file will fail.

What I used is the following:

- store your data from QVW to CSVs automatically (via QMC task).

- create 2 PowerShell scripts (one to copy all your CSV files and store them into 1 xlsx file) and anothter to delete the xlsx file when it is not needed anymore.

- automate these 2 PowerShell scripts via MS Windows Task Manager.

Hope this helps.

jakfourie
Partner - Contributor II
Partner - Contributor II
Author

Hi Denis,

Thank you for the input. What ended up working for us was to give the network admin a QlikView License and have his account run the Windows scheduler tasks.

did
Employee
Employee

Hi Jacques,

oh, great! I didn't know that.

But this means that: you automate the realod of QVW only via Windows scheduler task without refreshing the QVW through QMC, dont you?

jakfourie
Partner - Contributor II
Partner - Contributor II
Author

Hi Denis,

In our case we refresh with QMC, but let the Macro run with a variable from a .bat file

Inside .bat file:

"C:\Program Files\QlikView\qv.exe" /vvOnOpen=R /NoSecurity "C:\QlikView\QVDeploy\Live\Sales_Refreshed.qvw"

If statement in Macro checks variable vOnOpen.

did
Employee
Employee

Hi Jacques,

noSecurity... but still nice

Thank you.