maed Posted December 16, 2005 Author Share Posted December 16, 2005 (edited) maybe this $pos = MouseGetPos() MsgBox(0, "Mouse x,y:", $pos[0] & "," & $pos[1]) MouseMove($pos[0] + 5, $pos[1] + 5) 8) that was just telling me where it was... this thing that i need to move the cursor is a diff thign than what i originally made, it makes the links automatically so that the other program can paste it and go to it expandcollapse popupMsgBox ( 0, "Instructions", "Creates the link to invite from a list of names in a text file" ) #include <GUIConstants.au3> Dim $timer = 300; change to the "sleep" time you want Dim $t = 0 ; GUI GUICreate("Auto Inviter", 200, 150) ; BUTTON $RUN_1 = GUICtrlCreateButton("Run/Stop", 50, 50, 100, 50) HotKeySet("{PAUSE}", "TogglePause") Func TogglePause() Local $Paused $Paused = NOT $Paused While $Paused Sleep(100) WEnd EndFunc HotKeySet("{ESC}", "Terminate") Func Terminate() Exit 0 EndFunc ; GUI MESSAGE LOOP GUISetState() While 1 $MSG = GUIGetMsg() Select Case $MSG = $GUI_EVENT_CLOSE Exit Case $MSG = $RUN_1 If $t = 1 Then $t = 0 Else $t = 1 EndIf EndSelect If $t = 1 Then run_script() WEnd ;http://torax.outwar.com/managecrew.php?playername= Func run_script() Sleep ( 2000 ) ;------Need mouse to move down by 23 Y coordinate------ MouseClick ( "right" ) Send ( "P" ) Send ( "{DOWN}" ) Sleep ( 1000 ) MouseClick ( "left" ) Sleep ( 1000 ) MouseDown ( "left" ) Sleep ( 1000 ) EndFunc;==>run_script Edited December 16, 2005 by maed Link to comment Share on other sites More sharing options...
JSThePatriot Posted December 16, 2005 Share Posted December 16, 2005 One quick thing. I know how to make the mouse move down to a certain position but how can i make it move down a certain amount like this example. the mouse is at x coord 65 move mous down by 5 x coord now the mouse is at 70 x coord. Can this be done? the only thing im finding is move to a specific coord not move down a certain amount Or since you already know the co-ordinates just take Valuater's example and apply it to your situation. Adding numbers to your already defined values will give you the 'move' you want. As far as the above about the _FileReadToArray() what troubles are you having with it. You would need to do something like...untested Dim $aFileLine _FileReadToArray("something.txt", $aFileLine) For $i = 0 To $aFileLine[0] Step 1 ClipPut($aFileLine[$i]) ;Do something with it here.. ClipGet()? Next That help more? JS AutoIt Links File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out. ComputerGetInfo UDF's Updated! 11-23-2006 External Links Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more) Link to comment Share on other sites More sharing options...
maed Posted December 16, 2005 Author Share Posted December 16, 2005 Ok i got the mouse move right... Now i just need to get the readlinearray...I dont really understand anything about it, but i guess the way it does it now is fine, this little thing i got is not going to be good enough to go public lol! Thakns for all your guys help it really helped me alot even though i still dont udnerstand alot of it i elarned alot more just with your help. Link to comment Share on other sites More sharing options...
JSThePatriot Posted December 16, 2005 Share Posted December 16, 2005 Ok i got the mouse move right... Now i just need to get the readlinearray...I dont really understand anything about it, but i guess the way it does it now is fine, this little thing i got is not going to be good enough to go public lol! Thakns for all your guys help it really helped me alot even though i still dont udnerstand alot of it i elarned alot more just with your help.My above post not help any? I didnt look into the inner-workings of the function. I just know it reads a single line and populates an array with it. It is quite handy. I just recently used it on a project of mine I have yet to finish.If you can ask something a bit more specific than you dont understand it please I would be more than happy to explain to the best of my ability.JS AutoIt Links File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out. ComputerGetInfo UDF's Updated! 11-23-2006 External Links Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more) Link to comment Share on other sites More sharing options...
Valuater Posted December 16, 2005 Share Posted December 16, 2005 maybe... ( cleaned up too! ) expandcollapse popup#include <GUIConstants.au3> Dim $timer = 300; change to the "sleep" time you want Dim $t = 0 HotKeySet("{ESC}", "Terminate") HotKeySet("{PAUSE}", "TogglePause") ; GUI GUICreate("Auto Inviter", 200, 150) ; BUTTON $RUN_1 = GUICtrlCreateButton("Run/Stop", 50, 50, 100, 50) ; GUI MESSAGE LOOP GUISetState() While 1 $MSG = GUIGetMsg() Select Case $MSG = $GUI_EVENT_CLOSE Exit Case $MSG = $RUN_1 If $t = 1 Then $t = 0 Else $t = 1 EndIf EndSelect If $t = 1 Then run_script() WEnd ; ---------------------------------- Functions ----------------------------- Func TogglePause() Local $Paused $Paused = NOT $Paused While $Paused Sleep(100) WEnd EndFunc Func Terminate() Exit 0 EndFunc ;http://torax.outwar.com/managecrew.php?playername= Func run_script() Sleep ( 2000 ) ;------Need mouse to move down by 23 Y coordinate------ $pos = MouseGetPos() MouseClick ( "right", $pos[0], $pos[1] + 23 ) Send ( "P" ) Send ( "{DOWN}" ) Sleep ( 1000 ) MouseClick ( "left" ) Sleep ( 1000 ) MouseDown ( "left" ) Sleep ( 1000 ) EndFunc;==>run_script 8) 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