Forum Discussion
mesg2anil
13 years agoRegular Contributor
Hi,
Try below code...
CloseAllIEProcess
Try below code...
Sub CloseAllIEProcess
CloseAllIEProcess
IExplore = Sys.FindAllChildren("ProcessName","iexplore")
If UBound(iexplore)>=0 Then
For i = UBound(iexplore) to LBound(iexplore) Step -1 ' <== iterate from top to bottom
iexplore(i).Terminate
Next
End If
End Sub
=================================
After terminating IE forcibly, if you run any script immediately, please add below code, this will take IE to home page...
If Sys.Process("iexplore").WaitWindow("#32770", "Windows Internet Explorer", 1, 1000).Exists Then
Sys.Process("iexplore").Window("#32770", "Windows Internet Explorer", 1).Window("DirectUIHWND", "", 1).Window("CtrlNotifySink", "", 8).Window("Button", "Go to your home page", 1).Click
End If
Related Content
- 11 years ago
Recent Discussions
- 12 hours ago