48 readings and nobody can help me ?
Please who can take some time for to help me ?
Thanks
Hi,
I have a little programme autoit (thanks again John) with 5 commands
_WHEELUP()
_WHEELDOWN()
_CLICKRIGHT()
_SLIDEON()
_SLIDEOFF
Who call:
In a screen I have defines 5 buttons:Code:Func _WHEELUP() WinActivate ($WindowsName) MouseMove(500, 300, 10) MouseWheel("up", 5) EndFunc Func _WHEELDOWN() WinActivate ($WindowsName) MouseMove(500, 300, 10) MouseWheel("down", 5) EndFunc Func _CLICKRIGHT() WinActivate ($WindowsName) MouseMove(500, 300, 10) MouseClick("right", 500, 300, 1, 10) EndFunc Func _SLIDEON() WinActivate ($WindowsName) MouseClick("left", 380, 80, 1, 10) EndFunc Func _SLIDEOFF() WinActivate ($WindowsName) MouseMove(5, 80) MouseClick("left", 5, 80, 1, 10) EndFunc
Code:/, B, x, y, w, h, Command;COMMANDCODES, Tooltip B08,269,543,64,64,"","Mouse Right" B08,336,542,64,64,"WHEELDOWN","Roll Down" B08,73,543,64,64,"WHEELUP","Roll Up" B08,138,544,64,64,"","Mouse Left" B08,204,543,64,64,"CLICKRIGHT","Right Click"
In my autoit exe i have some test but don't run :
Code:If $rr.GetInfo("WHEELUP") Then _WHEELUP() If $rr.GetInfo("WHEELDOWN") Then _WHEELDOWN() If $rr.GetInfo("CLICKRIGHT$") Then _CLICKRIGHT() If $rr.GetInfo("SLIDEON$") Then _SLIDEON() If $rr.GetInfo("SLIDEOFF") Then _SLIDEOFF()
Who can help me and say me what i must to do .
Thanks![]()
48 readings and nobody can help me ?
Please who can take some time for to help me ?
Thanks
http://www.mp3car.com/vbulletin/road...t-program.html
Some of the code in that thread is available with the SDK examples provided with the installer. All you have to do is add that code from post #5 of that thread, then where there's the "this"/"that" you'll compare the cmd received with a command to execute each of your 5 functions. Then on the RR side you'll use the SENDMSG;Receiver;<COMMAND> on each button you made (so it executes each corresponding function in the autoit script). That thread shows an alternate way of doing things too, but what I just described is likely the best choice.
Should look like this (UNTESTED):
In RR:Code:Global Const $StructDef_COPYDATA = "ptr;dword;ptr" Global Const $WM_COPYDATA = 0x4A Global Const $WM_CLOSE = 0x10 Global Const $STRUCTDEF_AU3MESSAGE = "char[255]" Dim $cmd ; Create Reciver window $hwmd_Reciver = GUICreate("PierReceiver") ; Register Windows Messages GUIRegisterMsg($WM_COPYDATA, "_GUIRegisterMsgProc") GUIRegisterMsg($WM_CLOSE, "_GUIRegisterMsgProc") ;Loop indefinitely - put your commands in here While 1 If $cmd = "WHEELUP" Then $cmd = "" _WHEELUP() Endif If $cmd = "WHEELDOWN" Then $cmd = "" _WHEELDOWN() Endif If $cmd = "CLICKRIGHT" Then $cmd = "" _CLICKRIGHT() Endif If $cmd = "SLIDEON" Then $cmd = "" _SLIDEON() Endif If $cmd = "SLIDEOFF" Then $cmd = "" _SLIDEOFF() Endif Sleep(250) WEnd ; Message Handler Func _GUIRegisterMsgProc($hWnd, $MsgID, $WParam, $LParam) If $MsgID = $WM_COPYDATA Then ; We Recived a WM_COPYDATA Message ; $LParam = Poiter to a COPYDATA Struct $vs_cds = DllStructCreate($StructDef_COPYDATA, $LParam) ; Member No. 3 of COPYDATA Struct (PVOID lpData;) = Pointer to Costum Struct $vs_msg = DllStructCreate($STRUCTDEF_AU3MESSAGE, DllStructGetData($vs_cds, 3)) $SciTECmdLen = DllStructGetData($vs_cds, 2) $cmd = StringLeft(DllStructGetData($vs_msg, 1), $SciTECmdLen) ; Display what we have recived ; MsgBox(0, "Test String", $cmd) ElseIf $MsgID = $WM_CLOSE Then ; We Recived a WM_CLOSE Message Exit EndIf EndFunc ;==>_GUIRegisterMsgProc
Code:/, B, x, y, w, h, Command;COMMANDCODES, Tooltip B08,269,543,64,64,"","Mouse Right" B08,336,542,64,64,"SENDMSG;PierReceiver;WHEELDOWN","Roll Down" B08,73,543,64,64,"SENDMSG;PierReceiver;WHEELUP","Roll Up" B08,138,544,64,64,"","Mouse Left" B08,204,543,64,64,"SENDMSG;PierReceiver;CLICKRIGHT","Right Click"
Ride Runner RR's Myspace
"Being happy is not about having what you want, it's about wanting what you have."
"The best things in life are always free - but that doesn't mean money can't buy you good things."
Bookmarks