Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a bat to take care of some reloads.
It fails because Qlikview opens and asks if the document should be replaced. Of course the whole purpose of this bat is to not have manual clicks.
What am I missing?
This is my command:
set source=D:\QVS01\DistributionFolder\New\
set currentqvw=document_2.11.qvw
set archiveqvw=document_2.11.old
set sourceqvw=document_2.12.qvw
set sourceqvs="document.qvs"
set reloadcommand="C:\Program Files\QlikView\QV.exe"
set reloadswitch1=/r
CD "D:\QVS01\QVAPPS\somefolder"
ren %currentqvw% %archiveqvw%
CD %source%
copy %sourceqvw% "D:\QVS01\QVAPPS\somefolder"
cd %source%
copy %sourceqvs% "D:\QVS01\QVAPPS\somefolder"
CD "D:\QVS01\QVAPPS\somefolder"
%reloadcommand% %reloadswitch1% D:\QVS01\QVAPPS\somefolder\%sourceqvw%
etc. etc.
Found it.
User preferences: Save before reload.
Unchecked this and it works as expected.
You can add "/y" to the end of the copy command line to overwrite the file without needing a manual confirmation.
So instead of:
copy %sourceqvs% "D:\QVS01\QVAPPS\somefolder"
use:
copy %sourceqvs% "D:\QVS01\QVAPPS\somefolder" /y
I wrote my question not clear enough.
Copy command is ok. It's the command line reload statement which asks for replacing the file.
/Y didn't solve this issue.
So this statement asks for the replacement of the file:
%reloadcommand% %reloadswitch1% D:\QVS01\QVAPPS\somefolder\%sourceqvw%
Found it.
User preferences: Save before reload.
Unchecked this and it works as expected.