Title: RE: Running Perl Script through Windows 2000 Task Scheduler

well, i tried all methods that everyone mentioned but it didnt work, still confuse when i directly run the script from a command prompt its work, and when trying from Win 2000/NT schedular it didnt. anyhow, I use the Win32::Message extension to use the same thing as mentioned in Roths Book.

Roth, I have a question, can i use that extension to send message from win 2000 server, or i only send message from NT?
thanks,
-Moin Khan

-----Original Message-----
From: Jing Wee [mailto:[EMAIL PROTECTED]]
Sent: Friday, May 31, 2002 12:54 PM
To: [EMAIL PROTECTED]
Cc: Khan, Moin; [EMAIL PROTECTED]
Subject: RE: Running Perl Script through Windows 2000 Task Scheduler


I think the problem is the missing path in
         system("test.bat")
unless test.bat is in the same directory as the Task Scheduler.

So, add the path in e.g. system("c:\somewhere\test.bat");

Jing Wee


>In your batch file, specify the full path to the net.exe command, i.e.
>
>c:\winnt\system32\net send moin TEST
>    or
>c:\windows\command\net send moin TEST
>
>Sometimes the task scheduler doesn't see the file path, and needs explicit
>directions to get to
>the file.
>
>Hope this helps,
>
>--Chuck
>
>--- "Khan, Moin" <[EMAIL PROTECTED]> wrote:
> > Yes, i tried running script but same result, and yes permission are set
> > fine, the user have local admin on machine, I did one more thing,
> create the
> > batch file and only content of the batch is 'net send moin TEST', and use
> > that batch file in my script in as system("test.bat"), and now when I run
> > the script I got the error on console window as net is unknown command, wht
> > i realize is that when i am running the script in command window it able to
> > use shell commands but when i am executing script thru scheduler it not
> able
> > to execute shell commands, any comments?
> >
>
>
>__________________________________________________
>Do You Yahoo!?
>Yahoo! - Official partner of 2002 FIFA World Cup
>http://fifaworldcup.yahoo.com
>_______________________________________________
>Perl-Win32-Admin mailing list
>[EMAIL PROTECTED]
>To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to