Public Sub ie_quit()
Dim objShell
Dim objWindow
Set objShell = CreateObject("Shell.Application")
For Each objWindow In objShell.Windows
If TypeName(objWindow.Document) = "HTMLDocument" Then
objWindow.Quit
Sleep 100
End If
Next
Set objShell = Nothing
End Subネタ元