Anyone familiar with autoit?
I have been working to use vbscript and AutoItX to send keystrokes to a guest OS in vmware, but am having some difficulty.
Here is my code:
Set oAutoIt = CreateObject("AutoItX3.Control")
oAutoIt.ControlFocus "Local host - VMware Server Console","",""
WScript.Sleep 1000
oAutoIt.ControlSend "Local host - VMware Server Console","","","!m"
WScript.Sleep 500
oAutoIt.ControlSend "Local host - VMware Server Console","","","g" 'This grabs the input
WScript.Sleep 500
wscript.Echo oAutoIt.ControlSend("Local host - VMware Server Console","","VMWare.GuestWindow1","password")
WScript.Sleep 500
wscript.Echo oAutoIt.ControlSend ("Local host - VMware Server Console","","VMWare.GuestWindow1","{ENTER}")
I am able to change focus to the main vmware window, etc. But, nothing ever gets entered into the guest OS.
I know that it can be done, but since I have to be able to use the Control-series of commands since the workstationw ill be locked during this operation, I can't use
anything like SendKeys.
What am I doing wrong?
"Would you like to touch my monkey?" - Dieter (Mike Meyers)
"It is better to die like a tiger, than to live like a pussy."
-Master Wong, from Balls of Fury