Task scheduler: nothing happens

G

Guest

I'm trying to configure a task in task scheduler
The task starts running at the scheduled time but the actual application I want to execute is not launched. Actually nothing happens, only the status indicatior in the task scheduler window changes to 'running' .
No error message is written to the event log, no error message can be found in the task scheduler's log file.
I log on as domain\administrator (on a windows 2000 server SP4) and use the same credentials for the task itself
The task scheduler service logs on as the local system account and 'allow service to interact with desktop' is checked. Unchecking the checkbox (and stopping/restarting service) doesn't resolve the problem.
For testing purposes I simply scheduled calculator...
When I execute calculator from within the run box, it starts as expected.
What am I doing wrong?

Thanks.

Leo Leys
 
J

Jerold Schulman

On Mon, 14 Jun 2004 06:08:01 -0700, "Leo Leys" <Leo
I'm trying to configure a task in task scheduler
The task starts running at the scheduled time but the actual application I want to execute is not launched. Actually nothing happens, only the status indicatior in the task scheduler window changes to 'running' .
No error message is written to the event log, no error message can be found in the task scheduler's log file.
I log on as domain\administrator (on a windows 2000 server SP4) and use the same credentials for the task itself
The task scheduler service logs on as the local system account and 'allow service to interact with desktop' is checked. Unchecking the checkbox (and stopping/restarting service) doesn't resolve the problem.
For testing purposes I simply scheduled calculator...
When I execute calculator from within the run box, it starts as expected.
What am I doing wrong?

Thanks.

Leo Leys
See if it is running in the background. See tip 4579 in the 'Tips & Tricks' at
http://www.jsiinc.com

Jerold Schulman
Windows: General MVP
JSI, Inc.
http://www.jsiinc.com
 
P

Pegasus \(MVP\)

Leo Leys said:
I'm trying to configure a task in task scheduler
The task starts running at the scheduled time but the actual application I
want to execute is not launched. Actually nothing happens, only the status
indicatior in the task scheduler window changes to 'running' .
No error message is written to the event log, no error message can be
found in the task scheduler's log file.
I log on as domain\administrator (on a windows 2000 server SP4) and use
the same credentials for the task itself
The task scheduler service logs on as the local system account and 'allow
service to interact with desktop' is checked. Unchecking the checkbox (and
stopping/restarting service) doesn't resolve the problem.
For testing purposes I simply scheduled calculator...
When I execute calculator from within the run box, it starts as expected.
What am I doing wrong?

Thanks.

Leo Leys

The calculator is not suitable to test the Task Scheduler, because the Task
Scheduler is designed to run in the background whereas the Calculater
requires keyboard input. Schedule this batch file instead:

@echo off
echo %date% %time% Start of task > c:\test.log
c:\tools\YourApp.exe 1>>c:\test.log 2>c:\test.err
echo %date% %time% End of task >> c:\test.log

Now schedule your task, then examine the two log files, and all will become
clear.
 
P

Pegasus \(MVP\)

It probably works because a Command Processor (cmd.exe) is automatically
invoked when running the batch file. This may not be the case for your VB
application. You can force it by using a command line similar to

cmd.exe /c YourVB_Script


Leo Leys said:
I scheduled the batch file you proposed and... it works with my VB application.
No errors, normal execution. Problem resolved.
So that's very good news.
Thank you very much for your accurate help.

But: why does the same (VB) application fail to run when it is launched
from within the "run" textbox in task scheduler? It's exactly the same
application, the same user/password. The only difference is that the
application is triggered from within a batch file.
 
L

Larry Nguyen

Hi All,
I got a similar problem on some of my servers. The
applications (I did not use Calculator but Notepad and
IExplorer, and my own DOS scripts) that I tried to
schedule, work just fine on the other servers and I did
not have to code any DOS scripts to invoke to the
applications. Please help.

Larry
-----Original Message-----
I scheduled the batch file you proposed and... it works with my VB application.
No errors, normal execution. Problem resolved.
So that's very good news.
Thank you very much for your accurate help.

But: why does the same (VB) application fail to run when
it is launched from within the "run" textbox in task
scheduler? It's exactly the same application, the same
user/password. The only difference is that the application
is triggered from within a batch file.
 
P

Pegasus \(MVP\)

I suggest you use the debugging technique I recommended
in my first reply to the OP.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top