fielpo 0 Posted June 25, 2011 hi i have a problem with the function if not winexist... i need that it reconise a windows, but the windows have every time a different tile but some words are the same i have this code run( @AutoItExe & " /AutoIt3ExecuteScript mysoftware.exe ") ; <<<<< Test using Notepad. Sleep ( 10000 ) ; <<<<< Wait for CMD to Start. While 1 If Not Wintext("A WORD FROM TITLE") Then $PID = Run( @AutoItExe & " /AutoIt3ExecuteScript mysoftware.exe ") ; <<<<< Use AU3Info Tool in SciTE > Tools to get the CLASS name of the Window. Sleep(5000) ; Sleep Wait. WEnd Exit NOW IF I TEST IT WITH NOTEPAD OR CMD it works fine but if i use with what i need and put just a word from title it doesen't reconize so it start to open windows in loop... Share this post Link to post Share on other sites
somdcomputerguy 103 Posted June 25, 2011 Search WinTitleMatchMode in Help file. I believe that will resolve your situation. - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change. Share this post Link to post Share on other sites
Andreik 66 Posted June 25, 2011 AutoItSetOption("WinTitleMatchMode",2) or a dirty way to check with StringInStr() the word you looking for. When the words fail... music speaks Share this post Link to post Share on other sites
fielpo 0 Posted June 25, 2011 thanks you save me just added Opt("WinTitleMatchMode", 2) and now work well thanks again Share this post Link to post Share on other sites