I have an automation program that I'm developing that is doing most of what I want it to do. I can open various web browsers without a problem.
When it comes to closing them, Firefox, Opera and Safari all close fine using the code
Dim p As Process() = Process.GetProcessesByName(SelectedBrowserName)
For i = 0 To p.Count - 1
Do Until p(i).HasExited = True
Google Chrome however doesn't respond at all. The only way I can get it to close is to use the 'kill' command which causes some grief when I next load up Chrome.
I'm not 100% certain, but I'm pretty sure it used to work fine and has only started doing this in recent updates. Can anybody offer a suggestion that reliably works with the current version of Chrome?