Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
It seems that you can have processes started, but not have them appear to the user, as in query a bunch of info and create a log of some sort.
What i am trying to accomplish is sending key strokes to a series of windows, to restart reports that should be running in those windows, kinda like running "top" in telnet, on said remote machine. Am I on a fishing trip here? can this be done, either through WMI or AT command, or something else?
In a nutshell, with some careful planning and use of the proper privileges you might be able to write a script that WMI can launch on a remote system, and then that script might be able to alter the proper permissions in order to permit child processes that it creates to access the desktop. There's a lot of IF's in there. I wouldn't bet the farm on being able to do it, though, as attempting to do that is basically attempting to circumvent security features that are built into the Windows NT platform, and which exist for a good reason. Allowing processes running under other user's credentials to interact with the desktop can result in a loss of privacy & security w/respect to the data & programs being run by the user on the interactive console.
On trick involves using WMIs Win32_ScheduledJob to launch the processes locally on the remote machine. To do this we connect to the WMI service on the remote machine and then use the GET method to connect to the Win32_ScheduledJob class.
compiledscript = 'c:\temp\interactiveWB.exe' UTC_Time = '********104500.000000-420' ; Run at 10:45 AM interactive = @True servername = 'server01' ; Copy the script to the remote computer FileCopy( compiledscript, '\\' : server : '\C$\script\*.*', @True ) ; Schedule job to run on the remote computer using the interactive flag. objWMIService = ObjectGet( 'winmgmts:\\' : server : '\root\cimv2' ) objJob = objWMIService.Get( 'Win32_SceduledJob' ) ret = objJob.Create( compiledscript, UTC_Time, @False, 2, , interactive, '' ) objJob = 0 objWMIService = 0Because your compiled script is started locally on the remote machine, that means it will run in a visibile window and be totally interactive. Any dialogs displayed ny the script will be accessible to the end user.
Article ID: W16757
File Created: 2012:11:14:10:50:08
Last Updated: 2012:11:14:10:50:08