Sign in to follow this  
Followers 0
xcxooxl

how can i use winwait here?

16 posts in this topic

i want to build somthing that will work only when im talking to somone on ICQ/MSN

but when you open a conversion windows it goes by this

nickname - Message

and the first part of the name is always changing so how i can make it target the window by the last part?

or like "*anything* - Message"

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Maybe an adaptation of this

$sText = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\", "Window Title")

Edited by Hatcheda

Share this post


Link to post
Share on other sites

Maybe an adaptation of this

$sText = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\", "Window Title")

I dont understand how this can help me

Share this post


Link to post
Share on other sites

bump

please i realy want to finish with this

Share this post


Link to post
Share on other sites

Use Opt("WinTitleMatchMode",2)

It makes it match any substring in the title. So you'll only have to use "Message"

Share this post


Link to post
Share on other sites

AutoItSetOption("WinTitleMatchMode", 2)
WinWaitActive("- Message")

?


I ran. I ran until my muscles burned and my veins pumped battery acid. Then I ran some more.

Share this post


Link to post
Share on other sites

thank you its working now :)

Share this post


Link to post
Share on other sites

sorry for the double but now i got other problem

i need it will detect for MSN and ICQ in the same time

and MSN window names goes like this

NickName - Conversation

and also i want that it will always work i mean after doing the action

i need it to keep detecting windows and such

like return the action over and over agien and not only 1 time and exit script

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

AutoItSetOption("WinTitleMatchMode", 2)
while 1
If WinExists("- Message")Then do icq stuff
If WinExists("- Conversation")Then do msn sutff
HotKeySet("^s", "Stop")
wend
func Stop()
   Exit 0
EndFunc

Press ctrl+s to stop the script

Edited by muhmuuh

I ran. I ran until my muscles burned and my veins pumped battery acid. Then I ran some more.

Share this post


Link to post
Share on other sites

$msn = winwaitactive= " - converastion"

While 1

if $msn = 1 then (run your process)

sleep (1000)

wend

?????


" I haven't failed. I've just found 10,000 ways that won't work." Thomas Edison "You cannot help men permanently by doing for them what they could and should do for themselves." Abraham Lincoln

Share this post


Link to post
Share on other sites

10x agien now i need to hide the window with SW_HIDE but while hiding i want it to type somthing like

"Auto msg im busy! talk with me later and please do not respond to this msg "

Share this post


Link to post
Share on other sites

Well you could do Send("Auto msg im busy! talk with me later and please do not respond to this msg " & {enter}) if the text area is active.


" I haven't failed. I've just found 10,000 ways that won't work." Thomas Edison "You cannot help men permanently by doing for them what they could and should do for themselves." Abraham Lincoln

Share this post


Link to post
Share on other sites

#13 ·  Posted (edited)

If WinExists("- Message")Then 
  WinActivate("- Message")
  WinWaitActivate("- Message")
  send("wazaaaa{ENTER}")
  WinSetState("- Message", "", @SW_HIDE)
EndIf

Same for MSN

Edited by muhmuuh

I ran. I ran until my muscles burned and my veins pumped battery acid. Then I ran some more.

Share this post


Link to post
Share on other sites

If WinExists("- Message")Then 
  WinActivate("- Message")
  WinWaitActivate("- Message")
  send("wazaaaa{ENTER}")
  WinSetState("- Message", "", @SW_HIDE)
EndIf

Same for MSN

lol wazaaaaaaaaaaaaaaaaaaaa to you

" I haven't failed. I've just found 10,000 ways that won't work." Thomas Edison "You cannot help men permanently by doing for them what they could and should do for themselves." Abraham Lincoln

Share this post


Link to post
Share on other sites

ty for all the help

i got another problem..

every time when i get a message it send the automsg but if its the same person it also does that..

i want it to remember to who it send

and if it alrdy send to somone so in the second time it will just hide the window

Share this post


Link to post
Share on other sites

you could write the names to an ini file. Look up wingettitle stringtrim, stringinstrg, iniwrite, and iniread. Now just get the title of the window, then use stringtrim to take off the - conversation and write the name to an ini file. Then before you send a message check if that name exists.

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