Sign in to follow this  
Followers 0
fairlyfrank

Help with input box

9 posts in this topic

I have been making an automator and I want to place some input boxes that you can insert mouse positions and then when I press start it goes to that place on the screen. Can you please help me out with this one? :">

Share this post


Link to post
Share on other sites



Do u want to make a gui because u said when I press start it will go to that place? Or do u just want to add a hotkeyset?

Share this post


Link to post
Share on other sites

Global $x = 0

Global $y = 0

Hotkeyset("(button u want to press 2 place coordinates)","place")

Hotkeyset("(button u want to press 2 move mouse)","move")

Func place()

$place2move = inputbox("cordinates","insert cordinates","coordinates")

$cordinate = stringsplit($place2move,",")

$x = $place2move[1]

$y = $place2move[2]

Endfunc

Func move()

Mousemove($x,$y)

Endfunc

While 1

Sleep(1)

Wend

Share this post


Link to post
Share on other sites

Forgot don't forget to put a comma between x and y to distinguish x and y

And change the hotkeyset to any button u want

Share this post


Link to post
Share on other sites

Forgot don't forget to put a comma between x and y to distinguish x and y

And change the hotkeyset to any button u want

THANK YOU VERY MUCH YOU ARE A TRUE HERO!!!!!!!!! I LOVE YOU MAN I DO :P

Share this post


Link to post
Share on other sites

THANK YOU VERY MUCH YOU ARE A TRUE HERO!!!!!!!!! I LOVE YOU MAN I DO :P

Easy big fella lol. I'm sure locomaestro feels the same way about you. :D

Kurt


Awaiting Diablo III..

Share this post


Link to post
Share on other sites

Easy big fella lol. I'm sure locomaestro feels the same way about you. :P

Kurt

Kurt how do you involve that script into a GUI????

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

For example:

#include <Guiconstants.au3>
GuiCreate("MouseMovements")
$x  = GuiCtrlCreateinput("",10, 5)
$y  = GuiCtrlCreateinput("",10,30)
$go = GuiCtrlCreatebutton("Move the mouse!", 10, 70)
GuiSetState()
While 1
      $msg = GuiGetMsg()
      Select
            Case $msg = $GUI_EVENT_CLOSE
                  Exit
            Case $msg = $go
                  $x1 = GuiCtrlRead($x)
                  $y1 = GuiCtrlRead($y)
                  Msgbox(0,"","Now moving mouse to: " & $x1 & ", " & $y1)
                  MouseMove($x1, $y1)
      EndSelect
WEnd

UNTESTED

1st input = the X position of the mousemove

2nd input = the Y position of the mousemove

Tell me if that's not what you want and I will be glad to help,

Kurt

Edited by _Kurt

Awaiting Diablo III..

Share this post


Link to post
Share on other sites

For example:

#include <Guiconstants.au3>
GuiCreate("MouseMovements")
$x  = GuiCtrlCreateinput("",10, 5)
$y  = GuiCtrlCreateinput("",10,30)
$go = GuiCtrlCreatebutton("Move the mouse!", 10, 70)
GuiSetState()
While 1
      $msg = GuiGetMsg()
      Select
            Case $msg = $GUI_EVENT_CLOSE
                  Exit
            Case $msg = $go
                  $x1 = GuiCtrlRead($x)
                  $y1 = GuiCtrlRead($y)
                  Msgbox(0,"","Now moving mouse to: " & $x1 & ", " & $y1)
                  MouseMove($x1, $y1)
      EndSelect
WEnd

UNTESTED

1st input = the X position of the mousemove

2nd input = the Y position of the mousemove

Tell me if that's not what you want and I will be glad to help,

Kurt

Thank you very much sir :P

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