Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
linoyel
Specialist
Specialist

Run cmd file in Windows task scheduler in Qlikview server

Hi,

I have a c# code that opens a qvw document and sends mail based on the document data.

I need it to be sent once a day, so I wrote a cmd file that works perfectly if I press on it.

The problem starts when I'm putting it in Windows task scheduler - it's not doing anything, and it seems to me it's getting stuck while trying opening Qlikview.

What am I doing wrong?

Is there another way of scheduling the execution of a batch file in BI server?

Thanks.

23 Replies
iliyansomlev
Partner - Creator II
Partner - Creator II

Hi,

you have to tick "Run with highest privileges" box when you schedule the task

We are able to send emails when user is not logged on, provided it is  a system user and has a license, via Windows Scheduler on WinServer 2008 R2. It is done by executing a bat file that opens QVW document and reloads it without closing it. Macro runs after reload , sends mail and closes the document without saving it. It has been working fine.

If you don't need to reload but just open the document and it doesn't start the macro that way, you still can build a workaround by introducing a statement like

if "hour of reload = your hour" then

(some statement to finish reload right away)

else (your full reload)

in your script and then do the reload and execute the macro via the bat file as we do.

Hope this helps you

Not applicable

Hi lliyan:

How do you close the document without saving it? Do you do that in the batch file using force to close or you do that in the macro?

Also, open, reload and leave open using the batch file will not return any values. Did you use pin to keep the batch file keep running? If so, how long does it take for you to wait and how long is your reload?

I have post some question here. Maybe you can help.

Issue with automating PDF and email using Windows Task Scheduler

Thank you very much.

PC

shane_spencer
Specialist
Specialist

Linoy did you get this working? I've got exactly the same issue.

fkeuroglian
Partner - Master
Partner - Master

Hi experts!

 

Can anyone can resolve this point?

 

Thanks

 

Fernando