Re: Scheduling Jobs using WMI
- From: "Jonathan Liu [MSFT]" <jonliu@xxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 29 Aug 2005 16:33:49 -0700
This is not possible with this class.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
"Ravi" <ravikanth.chaganti@xxxxxxxxx> wrote in message
news:1121351906.981910.84330@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Hi all,
>
> I am trying to invoke an application on a remote server. I would want
> that application to be interactive and so I am not using Win32_Process
> to invoke the app. Instead, I am using Win32_ScheduledJob.Create method
> to schedule the job. Here is my code:
> strComputer = "Mars"
> Set objWMIService = GetObject("winmgmts:" _
> & "{impersonationLevel=impersonate}!\\" _
> & strComputer & "\root\cimv2")
> JobID = "MailLocator"
> Set objNewJob = objWMIService.Get("Win32_ScheduledJob")
> errJobCreate = objNewJob.Create _
> ("MailLocator.exe", "********154900.000000-420", _
> , , ,True, JobId)
>
> Now, I want the job to execute immediately after I create it. Something
> similar to "at now <command>".
>
> How can I do this using WMI?
>
> Thanks
> Ravi
>
.
- Prev by Date: Re: newbie problem - file revision & size
- Previous by thread: VB Script Help Please!, Win32_Share, CIM_DataFile, CIM_LogicalFile
- Index(es):
Relevant Pages
|
Loading