CygnusX1

Can not interact with a dialog box

3 posts in this topic

#1 ·  Posted (edited)

Hello, 

I have a dialog box that pops up during an install on a foreign OS. In this case Spanish. The dialog displays a message the program being installed needs to install .Net, CRT, and C++. When inspected the dialog it seems normal. I can get control IDs, Text, Position, everything. But when I try to have AutoIt interact with it e.g. move it, click a button, click on a control, ControlGetFocus, Send("{TAB}"), ControlClick(). Nothing works. What even weirder is I can WinActivate the dialog but then can't move the mouse with MouseMove. If I don't WinActivate(), I can use the MouseMove() function. I can not figure out how to interact with the dialog box.

Any thoughts on a way to interact with this dialog box?

Thanks.

 

 

 

dialog_box.png

Edited by CygnusX1

Cygnus

Share this post


Link to post
Share on other sites



did you try ?

 
Opt("WinTitleMatchMode", 4)

Sure is weird that you can activate the window but not do anything else, and the mouse issue..

How are you giving the title to the functions? just normal title, or did you try class or otherwise?


Spoiler

Paster - Main function is to paste text, but has more functions.

OpenW - Open With... alternative, Open any file with any application, set it's icon, set application as default.

Renamer - Rename files and folders, remove portions of text from the filename etc.

BeatsPlayer - Music player.

Params Tool - Right click an exe to see it's parameters or execute them.

Regedit Control - Registry browsing history, quickly jump into any saved key.

Time4Shutdown - Write the time for shutdown in minutes.

Power Profiles Tool - Set a profile as active, delete, duplicate, export and import.

Firefox Profile Backup - Backup/restore previously saved profile.

Finished Task Shutdown - Shuts down pc when specified window/Wndl/process closes.

NetworkSpeedShutdown - Shuts down pc if download speed goes under "X" Kb/s.

 

Share this post


Link to post
Share on other sites

Apparently, I left out one really important detail. I'm trying to automate on/in a Virtual Machine using VMWare. After doing a search I found this may not be possible. 


Cygnus

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Similar Content

    • ur
      By ur
      With the below command I am able to revert a virtual machine in vmware workstation to a snapshot mentioned.
      $sVMPath = <path of the vmx file of virtual machine> $sSnapshot = <snapshot name> $Ret = RunWait(@ComSpec & " /c VMRun.exe -T WS revertToSnapshot ""$sVMPath$"" ""$sSnapshot$"" nogui", "", @SW_HIDE) But the problem here is the virtual machine may contain multiple snapshots with same name because multiple users use same workstation and eventually they are keeping same name sometimes like below or in attachment.
      Both snapshots are with same name and in GUI we can use them with no issue.

       
      But with autoit or with vmrun command line it is showing error as 
      Error: The name does not uniquely identify one snapshot Could anyone please help me on this.
    • VIP
    • Second
      By Second
      Greetings, people of the interweb!
      I'm trying to get started on automating actions using the VMware API, but I reached a dead end.  I was trying out this example but it doesn't work for me at all. Line 9, Char 1, Object required: 'VixCOM'.
      All that I've done now is got a grasp of how the vmrun works via command line, but I do not find it enough for me.
      Could anyone point me at the correct direction or tell me what I'm doing wrong? (Please note that the script is in VBS, I want to get it working first, then continue translating it to AutoIT)
      Dim lib Dim host Dim job Dim vm Dim result Set lib = CreateObject("VixCOM.VixLib") ' Connect to the local installation of Workstation. This also initializes the VIX API. Set job = lib.Connect(VixCOM.Constants.VIX_API_VERSION, VixCOM.Constants.VIX_SERVICEPROVIDER_VMWARE_WORKSTATION, Empty, 0, Empty, Empty, 0, Nothing, Nothing) ' results needs to be initialized before it's used, even if it's just going to be overwritten. Set results = Nothing ' Wait waits until the job started by an asynchronous function call has finished. It also ' can be used to get various properties from the job. The first argument is an array ' of VIX property IDs that specify the properties requested. When Wait returns, the ' second argument will be set to an array that holds the values for those properties, ' one for each ID requested. err = job.Wait(Array(VixCOM.Constants.VIX_PROPERTY_JOB_RESULT_HANDLE), results) If lib.ErrorIndicatesFailure(err) Then ' Handle the error... End If ' The job result handle will be first element in the results array. Set host = results(0) ' Open the virtual machine with the given .vmx file. Set job = host.OpenVM("c:\Virtual Machines\vm1\win2000.vmx", Nothing) err = job.Wait(Array(VixCOM.Constants.VIX_PROPERTY_JOB_RESULT_HANDLE), results) If lib.ErrorIndicatesFailure(err) Then ' Handle the error... End If Set vm = results(0) ' Power on the virtual machine we just opened. This will launch Workstation if it hasn't ' already been started. Set job = vm.PowerOn(VixCOM.Constants.VIX_VMPOWEROP_LAUNCH_GUI, Nothing, Nothing) ' WaitWithoutResults is just like Wait, except it does not get any properties. err = job.WaitWithoutResults() If lib.ErrorIndicatesFailure(err) Then ' Handle the error... End If ' Wait until VMware Tools are running within the guest, with a 300 second timeout. Set job = vm.WaitForToolsInGuest(300, Nothing) err = job.WaitWithoutResults() If lib.ErrorIndicatesFailure(err) Then ' Handle the error... End If Set job = vm.LoginInGuest("vixuser", "secret", 0, Nothing) err = job.WaitWithoutResults() If lib.ErrorIndicatesFailure(err) Then ' Handle the error... End If Set job = vm.RunProgramInGuest("c:\myProgram.exe", "/flag arg1 arg2", 0, Nothing, Nothing) err = job.WaitWithoutResults() If lib.ErrorIndicatesFailure(err) Then ' Handle the error... End If Set results = Nothing Set job = Nothing Set vm = Nothing host.Disconnect() ITypeInfo Viewer showed me that the object name is correct, but the variables are inaccessable using both VixCom object and VIxCOM.VixLib.
      Note: https://www.vmware.com/support/developer/vix-api/ SDK from here is also installed on the machine.
      I have VMware workstation 10
      Any thoughts?