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

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Execute a batch file on the server

Hi all,

I want to execute a batch file on the server via a macro. I'm not used to create macro so i check the forum in order to find my response and i've found this subjet :

Server Side macro : http://community.qlik.com/forums/t/22605.aspx

When i try to execute the code below

sub launchbatPlain
Set objshell = createobject("Wscript.Shell")
sCmd = Chr(34) & "\\server\folder\mybatch.bat " & Chr(34)
objshell.Run(sCmd), 0, False
end sub

Is there something wrong in this macro ?

Thanks for answer.


2 Replies
rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

I don't think it's possible to execute server-side directly. You'll have to use one of the workarounds discussed in the other thread.

-Rob

Not applicable
Author

Just thinking out loud here...

If your batch script is stored on the server - and it has to be "fired" off via a QV app - can you not just load the URL into an Add Action (External) that is triggered OnPostReload in the Document Properties/Triggers ?

The QV can then be scheduled to reload as and when ?