I am trying to refresh a QV document which executes a macro through a post reload trigger. I can execute this fine either by using the following command in a .bat file or by executing the command directly in a command prompt:
"C:\Program Files\QlikView\qv.exe" /r "C:\QlikView Source\Manufacturing\ClearView\Export Test 2.qvw"
However, when I execute either a call to the batchfile or the refresh statement above directly, through the QEMC using a Command line statement in an External program, the task just hangs. I can see that the qv.exe process has executed as each time I can see it appear immediately in the Windows Task Manager but the task never ends until I kill the Windows process (it should only take about 2 seconds). Is there something I'm missing here? Maybe another command line switch?
I tried using the /nosecurity switch as below both directly in the external task command line and from a batch file being called from the external task command line. Both times I get the same result (the task hangs). Do you have any ideas of whether there are document or server settings that need to be made to allow this?
"C:\Program Files\QlikView\qv.exe" /r /NoSecurity "C:\QlikView Source\Manufacturing\ClearView\Export Test 2.qvw"
I've the exact same problem. I'm using a similar command like you have above.
I'm able to run this from the command line on the QV Server. I've also assigned a Named User license to the services account. I've turned off macro checking on the server and turned off similar check boxes in the Document Properties.
QV.exe starts, but it's not even generating the log file.
I got past this issue... We had to lease the license by connecting to prod server as the services account. Now, the issue is during macro execution. QV.exe dies, but Excel is still running. Macro is trying to find the selections, but QV is not there. Trying to figure out why QV dies.
I think the problem may be that the /r switch tells qv to exit after the reload. It doesn't hang around for the PostReload macro to run. A possible solution would be to code the macro as an external VBS routine that can be run with csrcipt.exe. The vbs can open the qv document, do the work, and close the document and exit.