1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to create a hotkey to press a button?

Discussion in 'Programming' started by vuvanthanh, Sep 5, 2011.

  1. vuvanthanh

    vuvanthanh Banned

    Joined:
    Sep 5, 2011
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    I have a POS software which doesn't support hotkey to press a certain button. I have to press this button very often and having always to use mouse is slow and uncomfortable.
    I tried to use AutoHotKey or AutoIt to emulate the mouse click. However, the problem is that AutoHotKey and AutoIt couldn't locate the button. This button control seems to be an internal object of the POS software and not visible to AutoHotKey and AutoIt.
    Any suggestions? Thanks!
     

    Attached Files:

  2. fabian1121

    fabian1121 New Member

    Joined:
    Mar 20, 2012
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    0
    MouseMove() to the pos of the button maybe ? wouldn't it be easiest, i mean in AutoIt3, check the pos by AutoIt 3 Window Info.
     
  3. phpdevelopment

    phpdevelopment New Member

    Joined:
    Jun 23, 2012
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    Home Page:
    You can work faster and more efficiently by using your keyboard instead of your mouse. HotKeyz is a keyboard utility that will boost your productivity and it is really great to use.

    Once you’ve done that, paste the following into the script:
    #Persistent
    SetTimer, PressTheKey, 1800000
    Return
    PressTheKey:
    Send, {Space}
    Returnz
     
  4. annaharris

    annaharris Banned

    Joined:
    May 4, 2012
    Messages:
    7
    Likes Received:
    1
    Trophy Points:
    0
    Place the window in the top-left corner of your screen. Record a macro that moves the pointer all the way to the top left corner of your monitor, then down to the button and clicks it. Then you can run your macro however often you like, because no matter where your mouse pointer is, it will zoom up to the top left corner, then down to the button.
     

Share This Page