NicePerson Posted June 26, 2010 Share Posted June 26, 2010 (edited) Hi guys i am new here and also new to this cute AutoIt language. i am writing a script to buzz yahoo chat screen with AutoIt but i don't know why it sends only G? have a look on cede and plz help ; Identify the Yahoo window ; Change into the WinTitleMatchMode that supports classnames and handles AutoItSetOption("WinTitleMatchMode", 4) $handle = WinGetHandle("[CLASS:CConvWndBase]") If @error Then MsgBox(4096, "Error", "Could not find the correct window") Else ; Ctrl + G is shortcut for buzzing but not working here it sends only G ControlSend($handle, "", "YIMInputWindow1", "{LCtrl}G") EndIf Edited June 26, 2010 by RMR Link to comment Share on other sites More sharing options...
kaotkbliss Posted June 26, 2010 Share Posted June 26, 2010 Have you tried ControlSend($handle, "", "YIMInputWindow1", "{CTRLDOWN}G{CTRLUP}") ? 010101000110100001101001011100110010000001101001011100110010000 001101101011110010010000001110011011010010110011100100001 My Android cat and mouse gamehttps://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek We're gonna need another Timmy! Link to comment Share on other sites More sharing options...
Inconspicuous Posted June 26, 2010 Share Posted June 26, 2010 It should be:ControlSend($handle, "", "YIMInputWindow1", "^g") http://www.autoitscript.com/autoit3/docs/functions/Send.htm Link to comment Share on other sites More sharing options...
NicePerson Posted June 26, 2010 Author Share Posted June 26, 2010 Thanks for replying but boths are not working!! is my question so difficult for experts??? Link to comment Share on other sites More sharing options...
NicePerson Posted June 26, 2010 Author Share Posted June 26, 2010 Hey if anyone did not understand my question then ask whatever you want about it but help me please?? It proves how helpful this forum is! Link to comment Share on other sites More sharing options...
bogQ Posted June 26, 2010 Share Posted June 26, 2010 (edited) It proves how helpful this forum is! Did you read rules from the forum about bumping your topic? ...that isnt someting to say when you did not provide enought info on your problem and did not read rules on forum. Are you trying to activate hotkey from other window? If thats the case did you try to use Send instead ControlSend? Send is difrent from controlsend in many wayes, one is used to send strings mostly to specific control, the other is used to send key strokes. Try If WinExists ( "[CLASS:CConvWndBase]" ) Then If Not WinActive ( "[CLASS:CConvWndBase]" ) Then WinActivate ( "[CLASS:CConvWndBase]" ) WinWaitActive ( "[CLASS:CConvWndBase]" ) EndIf Send ( "^g" ) Else MsgBox ( 0 , "" , "You dont have that win" ) EndIf if its working for you Edited June 26, 2010 by bogQ TCP server and client - Learning about TCP servers and clients connectionAu3 oIrrlicht - Irrlicht projectAu3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related) There are those that believe that the perfect heist lies in the preparation.Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost. Link to comment Share on other sites More sharing options...
NicePerson Posted June 26, 2010 Author Share Posted June 26, 2010 @bogQ Thanks its working! Link to comment Share on other sites More sharing options...
bogQ Posted June 26, 2010 Share Posted June 26, 2010 Dont tank me, Inconspicuous posted you the link to Send command in his post, dono why you did not try that command it in the first palce. You where one click to solution. TCP server and client - Learning about TCP servers and clients connectionAu3 oIrrlicht - Irrlicht projectAu3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related) There are those that believe that the perfect heist lies in the preparation.Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost. Link to comment Share on other sites More sharing options...
NicePerson Posted June 26, 2010 Author Share Posted June 26, 2010 (edited) OK Thanks but, one more question how to attach a text file or pic with autoit to yahoo chat window? Here is my try! If WinExists ( "[CLASS:CConvWndBase]" ) Then WinActivate ( "[CLASS:CConvWndBase]" ) WinWaitActive ( "[CLASS:CConvWndBase]" ) Send("D:\AVI-Songs\Akon\AKON-NA-NA-NA.avi") Else MsgBox ( 0 , "" , "You dont have that window" ) EndIf Edited June 26, 2010 by RMR Link to comment Share on other sites More sharing options...
bogQ Posted June 26, 2010 Share Posted June 26, 2010 (edited) Dont know how yahoo chat is working. If ctrl+c +v is working on files in yahoo chat then _ClipPutFile to load file and ctrl+v to send it to win shud work If yahoo chat dont have that option and have button or hotkey that activate that process then controlclick to click that option or send to activate it from meny or WinMenuSelectItem. then use send or control send for file path on win that request file path. Edited June 26, 2010 by bogQ TCP server and client - Learning about TCP servers and clients connectionAu3 oIrrlicht - Irrlicht projectAu3impact - Another 3D DLL game engine for autoit. (3impact 3Drad related) There are those that believe that the perfect heist lies in the preparation.Some say that it’s all in the timing, seizing the right opportunity. Others even say it’s the ability to leave no trace behind, be a ghost. Link to comment Share on other sites More sharing options...
NicePerson Posted June 26, 2010 Author Share Posted June 26, 2010 Thanks a lot again! Link to comment Share on other sites More sharing options...
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