How do I close the “Error” dialog shown below? I tried with the code below to look for “Error”, but no luck so far. I don’t know if it can be caused by the Spanish language setting on the PCs and I’m aiming for the wrong title or there’s something else I’m not taking into consideration.
Set oShell = CreateObject("WScript.Shell")
If oShell.AppActivate("Error") Then
WScript.Sleep 500
oShell.SendKeys "%{F4}"
End If
I have to mention that the test I performed is done on my personal PC. The working machines this has to be implemented on, they need to be in Spanish, just FYI, I can change the language and region settings creating a copy of the VM if it’s needed.
Images:
Sergio KYR is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
17