Avatar of Dooglave
Dooglave

asked on 

Is there a way to detect as soon as a dialoug window opens with vbs

Is there a way to tell exactly when this program is open rather than sleep and hope it's open?

Dim WshShell, ret
Set WshShell = Wscript.CreateObject("WScript.Shell")
WshShell.Run "uninstall.exe"
Wscript.Sleep 20000
ret = WshShell.AppActivate("Program")
If ret = False then
 Msgbox "Uninstall Failed Error Code: 0"
 Wscript.Quit
End If
 WshShell.SendKeys "{ENTER}"

Open in new window

Visual Basic ClassicVB Script

Avatar of undefined
Last Comment
nffvrxqgrcfqvvc

8/22/2022 - Mon