ChoosenOne Posted October 2, 2006 Share Posted October 2, 2006 (edited) Hi,Sorry to create another topic that talk about Controlsend, but i will don't know why So if someone can help me Well, i have an old script that send in a minimize windows some text.I try to send some text to the game but sometime he doesn't write what i have initialize....Here is the code :WinWaitActive("Game") While WinExists("Game") ControlSend("Game","","","450 EA 00 E2 AZ FE{Enter}") Sleep(650) ControlSend("Game","","","450 EA 00 12 2B F6{Enter}") Sleep(650) WendThat a sample of my codeThen when the run the macro Sometime it send what i want "450 EA 00 E2 AZ FE" but some time it send "450 éA0à00E20AZ FE"I really don't know where that unwanted text is coming from If someone have a solution!! My goal is to use my script and be able to do other things at the same time thx for all your helpChoosenOne Edited October 2, 2006 by ChoosenOne Link to comment Share on other sites More sharing options...
jinxter Posted October 2, 2006 Share Posted October 2, 2006 (edited) try using {SPACE} instead of space... ControlSend("Game","","","450{SPACE}EA{SPACE}00{SPACE}E2{SPACE}AZ{SPACE}FE{Enter}") Edited October 2, 2006 by jinxter > there are 10 types of people in the world, those who understand binary and those who don't. Link to comment Share on other sites More sharing options...
ChoosenOne Posted October 2, 2006 Author Share Posted October 2, 2006 Thx jinxter for ur help but it doesn't work i still have the same problem Sometime i don"t the space between the number Sometime i have somme unwilling caractere.... Have more clue ? :"> Link to comment Share on other sites More sharing options...
Xenobiologist Posted October 2, 2006 Share Posted October 2, 2006 Hi, have you tried it with the flag = 1 ? So long, Mega Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
ChoosenOne Posted October 2, 2006 Author Share Posted October 2, 2006 (edited) No i will try i tell u if u have found the solution to my problem thx dude!! Edited October 2, 2006 by ChoosenOne Link to comment Share on other sites More sharing options...
ChoosenOne Posted October 3, 2006 Author Share Posted October 3, 2006 to th.meger : I have try with the flag =1 (sent raw) but i still have the same problem I always have that unwanted caractere that insert themself from nowhere in my text.... Does it work if i'm doin' something like this WinWaitActive("Game") $FirstPacket="450 EA 00 E2 AZ FE" $SecondPacket="450 EA 00 E2 AZ FE" While WinExists("Game") ControlSend("Game","","",$FirstPacket,1) ControlSend("Game","","","{Enter}") Sleep(650) ControlSend("Game","","",$SecondPacket,1) ControlSend("Game","","","{Enter}") Sleep(650) Wend And is ControlSend the appropriate function to what i want to do ? When i try with the function send that work properly...Need some advise Link to comment Share on other sites More sharing options...
Xenobiologist Posted October 5, 2006 Share Posted October 5, 2006 Hi, I guess that problem seems to stay a mystery. So long, Mega Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
Bert Posted October 5, 2006 Share Posted October 5, 2006 This is something I have seen in my scripts as well. I've never been able to nail it down as to the cause. I tried slowing down what was sent, which helped, but even then, I needed something that was 100%. What I ended up doing was this. It does a error check to make sure what was sent is what I want. It is messy, but it does work well. Some will question why I repeat a "^c". I found if I didn't do this, sometimes it would fail. (about 10% of the time) It was the only way I could make it bullet proof that worked. ControlSend("Unicenter ServicePlus Service Desk - Change Order Search", "", "Internet Explorer_Server1", "{RIGHT}", 0) _F3b_chk1() $g = 1 While 2 $g = $g + 1 $aa = StringLen($iniread_5) Sleep(5) Send("^c") Sleep(5) Send("^c") ;this allows for error. Sometimes this fails, so it is done twice for safety. $clip = ClipGet() $bb = StringLen(String($clip)) Select Case $aa = $bb ExitLoop Case $g = 10 ExitLoop Case Else _F3b_chk1() ContinueLoop EndSelect WEnd Func _F3b_chk1() local $iniread_5 $iniread_5 = IniRead(@ScriptDir & "\bin\unplus.ini", @UserName, "search 5", "not found") Send($iniread_5) ClipPut("") Send("^a") Sleep(10) Send("^c") Sleep(5) Send("^c") ;this allows for error. Sometimes this fails, so it is done twice for safety. EndFunc ;==>_F3b_chk1 The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Xenobiologist Posted October 5, 2006 Share Posted October 5, 2006 Hi, did you already try ControlSetText or Clip funcs? Just to prove it works other way round? So long, Mega Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
ChoosenOne Posted October 5, 2006 Author Share Posted October 5, 2006 (edited) Hi,did you already try ControlSetText or Clip funcs? Just to prove it works other way round?So long,MegaI will try ControlSetText and tell if it work or not :"> I don't know the function Clip i am goin to get some information and try it I tell u if it workto vollyman : I can't repeat twice the same packet coz i will crash the client of my game ^^ Edited October 5, 2006 by ChoosenOne Link to comment Share on other sites More sharing options...
Xenobiologist Posted October 5, 2006 Share Posted October 5, 2006 Hi, ok. Clip was my short for ClipPut and ClipGet. :"> So long, Mega Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times 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