Sign in to follow this  
Followers 0
bills

Counting Internet Explorer windows?

6 posts in this topic

Hi everyone.

Im wondering if theres a way to have my script count the existing internet explorer windows and i there are more that 3 display a warning message?

One more thing i need help with is that i want my script to close the 3rd internet explorer window, but i wont know what it might be called, although i know the names of the windows not to be closed. they are "trafiksidan" and "bridge".

Im also wondering if i can have the script show itself from hidden when i press the taskbar icon.

Thanks for all your time and help :rolleyes:

//Bill

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Hi everyone.

Im wondering if theres a way to have my script count the existing internet explorer windows and i there are more that 3 display a warning message?

One more thing i need help with is that i want my script to close the 3rd internet explorer window, but i wont know what it might be called, although i know the names of the windows not to be closed. they are "trafiksidan" and "bridge".

Im also wondering if i can have the script show itself from hidden when i press the taskbar icon.

Thanks for all your time and help :rolleyes:

//Bill

To find out how many internet explorers you had open, one method would be to do the following:

AutoItSetOption ( "WinTitleMatchMode", 4 )
$var = WinList("[CLASS:IEFrame]")
$numIE = Ubound($var,1)-1
If $numIE > 3 Then
     msgbox(0, "UH OH", "NOOO TOO MANY IE OPEN!!!!!")
EndIf

Can't help you on the closing part, but I'm sure many people here could.

Edited by Leighwyn

Share this post


Link to post
Share on other sites

Okay, thanks :rolleyes:

Anyone who has an answer for the other 2 questions?

//Bill

Share this post


Link to post
Share on other sites

No one? Ive solved the taskbar-click part as well. so the only thing remaining is the ie-closing part.

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

This should work

While 1
If ProcessExists ("iexplore.exe") Then
    ProcessClose("iexplore.exe")
Else
ExitLoop
EndIf
Wend

EDIT: Sorry this will close all IEexplorer window and anyway how can it detect the 3rd window? You mean the 3rd IE windows that was open by the user?

Edited by J0ker

Share this post


Link to post
Share on other sites

Yeah that wont work. I want the script to close all IE windows except the ones named "Trafiksidan" and "Bridge".

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0