Guest Xauier Posted September 16, 2004 Posted September 16, 2004 Is it possible to make an if selection with AutiIt to search for two or more windows with the same name ?? Thx...
Guest BlackDiablo110 Posted September 16, 2004 Posted September 16, 2004 Checks to see if a specified window exists. WinExists ( "title" [, "text"] )
Guest Xauier Posted September 17, 2004 Posted September 17, 2004 yes... but what i need is to check it two or more windows with the same name exist!! With you if cause it is possible to find one window with a special name.... i need to find 2..or more but thx...
ZeDMIN Posted September 17, 2004 Posted September 17, 2004 Hiya, its a bit long winded, but it works: AutoItSetOption("WinTitleMatchMode", 4) $windowtitle = "Explorer - " Dim $winarr[20][2] $counter = 0 While WinExists($windowtitle) $winarr[$counter][0] = "handle=" & wingethandle($windowtitle) $winarr[$counter][1] = wingettitle($windowtitle) winsettitle($windowtitle,'',"Some new title" & $counter) $counter = $counter + 1 WEnd For $I = 0 to $counter-1 winsettitle($winarr[$I][0],'',$winarr[$I][1]) Next MsgBox(0,'',$counter) Gives you a popup with the number of Explorers you have open. If the windows you are searching for, really have EXACTLY the same titles, you can leave the saving of the windowtitles away. Greetings, ZeD
Westi Posted September 17, 2004 Posted September 17, 2004 (edited) If you use WinSetTitle ( "your windowtitle", "your text", "new windowtitle" )only the first window will be renamed. So you can rename your windows step by step.Try it, open two session of notepad.exe and execute:WinSetTitle ( "Untitled - Notepad", "", "First" ) WinSetTitle ( "Untitled - Notepad", "", "Second" )Of course, this works only if you know the number of the windows with the same title. Edited September 17, 2004 by Westi
Guest Xauier Posted September 17, 2004 Posted September 17, 2004 One more question.... is there a possibility to find processes (win2k) and close them without to get a messagebox ?
Matt @ MPCS Posted September 17, 2004 Posted September 17, 2004 Isn't ProcessList only in unstable 3.0.103? You should make that clear before suggesting it to newbies... that can get them all screwed up... lol.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now