Results 1 to 7 of 7

Thread: Shift+Control+Click

  1. #1
    Join Date
    Feb 2010
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Shift+Control+Click

    Hi,

    I have been working a web-browser script that requirest to click on links.

    The script cliks on a link and then calls a procedure with waits and keypresses to eventually return to the start page and refresh. And go back to the main script.

    So for every click it takes ~10 seconds to go back to the main page hunting for links. I realise a more efficient way to do this would be to open the new links in new browser tabs Which using FF is Control+Click or Opera is Shift+Control+Click. Once the links are open they can just stay open or for a more advanced idea, make a function to go around clicking on the "X" to close them.

    I have searched around for the byte which is Shift or Control, thinking of having a procedure that would hold the key, use the SRLs mouse click function then release the key. Problem is that I can't find how to press these keys from the script. I did find isfunctionkeydown() but what I want is not the test but to do it "functionkeydown"? Anyone can point me to the right source?

    Cheers

  2. #2
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    I think if you click the mouse wheel then it also opens up a new tab, so
    SCAR Code:
    ClickMouseMid(X, Y)

    Could work, I'll edit my post in a sec with the actual answer .

    Here:

    SCAR Code:
    Begin
      KeyDown(VK_Shift); //holds down shift
      KeyDown(VK_Control); //holds down control
      ClickMouse(X, Y, True); //clicks at 'x', 'y'.
      Wait(80); //waits for 80 msec
      KeyUp(VK_Shift);  //puts the key up
      KeyUp(VK_Control); //puts the key up
    End.
    Last edited by Naum; 02-21-2010 at 10:33 AM.

  3. #3
    Join Date
    Mar 2008
    Location
    New Jersey
    Posts
    1,673
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    Naum, can you tell us where you found that in case anyone else wants to know how to press other keys? Like is there a list somewhere that we can find that?

  4. #4
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Scar: Ctrl+Space and type in VK_, standard lol.

  5. #5
    Join Date
    Mar 2008
    Location
    New Jersey
    Posts
    1,673
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    oh I didn't know all those VK_ keys would show up in ctrl+space, and I use ctrl+space from time to time also. Thanks, I'm sure that'll come in handy for some people and probably even me one day.

  6. #6
    Join Date
    Jan 2007
    Posts
    8,876
    Mentioned
    123 Post(s)
    Quoted
    327 Post(s)

    Default

    Or do F1 and find the ASCII table

  7. #7
    Join Date
    Feb 2010
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Perfect, thanks!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •