Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 6 of 6
  1. #1
    Join Date
    May 2006
    Posts
    94

    Set Mouse Pos...

    Hi!
    How i can set the mouse position??
    Greetings!!

  2. #2
    Join Date
    May 2006
    Posts
    5,380
    ams cant set the mouse position, but you can use the sendkeys plugin to simulate a mouse click

    or i could make you a small addon (with autoit) that will actualy move the mouse cursor
    Open your eyes to Narcissism, Don't let her destroy your life!!

  3. #3
    Join Date
    May 2006
    Posts
    94
    Quote Originally Posted by RizlaUK View Post
    ams cant set the mouse position, but you can use the sendkeys plugin to simulate a mouse click

    or i could make you a small addon (with autoit) that will actualy move the mouse cursor
    Thanks a lot!!
    And please,make me the addon with autoit...
    Greetings!!
    PD:Sorry for my english,im from spain!

  4. #4
    Join Date
    May 2006
    Posts
    5,380
    here, the example is very easy to use the code is in the "Move" button

    you can set the position and speed that the mouse moves, you can use raw numbers

    ie:

    Code:
    sX = 100 
    sY = 100 
    speed = 0 
    
    result = File.Run( "AutoPlay\\Docs\\MouseMove.exe", sX..' '..sY..' '..speed, "", SW_SHOWNORMAL, false);
    output enhanced with AMS Code Pretty


    but if you use inputs like i did in this example then you must use "String.ToNumber"

    ie:

    Code:
    sX = Input.GetText( "x"); 
    sY = Input.GetText( "y"); 
    speed = Input.GetText( "speed"); 
    
    sX = String.ToNumber(sX); 
    sY = String.ToNumber(sY); 
    speed = String.ToNumber(speed); 
    
    result = File.Run( "AutoPlay\\Docs\\MouseMove.exe", sX..' '..sY..' '..speed, "", SW_SHOWNORMAL, false);
    output enhanced with AMS Code Pretty


    hope this helps

    FYI, this will not work on win 95, 98, 98se, or ME,
    Last edited by RizlaUK; 02-01-2009 at 11:35 AM.
    Open your eyes to Narcissism, Don't let her destroy your life!!

  5. #5
    Join Date
    Jul 2002
    Location
    USA
    Posts
    3,959
    Or you can use this which will work on all platforms

    Code:
    nResult = DLL.CallFunction(_SystemFolder.."\\User32.dll", "SetCursorPos", "25, 100", DLL_RETURN_TYPE_LONG, DLL_CALL_STDCALL)

  6. #6
    Join Date
    May 2006
    Posts
    5,380
    handy to know, cheers worm

    i should really read up on the user32.dll as i always seem to go the hard way about things
    Open your eyes to Narcissism, Don't let her destroy your life!!

Similar Threads

  1. buttons disappear
    By mgokkaya in forum AutoPlay Media Studio 6.0
    Replies: 5
    Last Post: 04-11-2008, 02:40 PM
  2. Debug set pos?
    By nrgyzer in forum AutoPlay Media Studio 6.0
    Replies: 2
    Last Post: 02-02-2006, 11:37 AM
  3. Example: Make an Image 'Follow' the Mouse Cursor
    By Desmond in forum AutoPlay Media Studio 5.0 Examples
    Replies: 0
    Last Post: 05-18-2004, 09:06 AM
  4. 1 AVI file = 1 Video + 2 Audio streams
    By dmla in forum AutoPlay Media Studio 4.0
    Replies: 0
    Last Post: 07-15-2003, 09:41 AM
  5. INFO: How to Set the Default Application Directory
    By Support in forum Setup Factory 6.0 Knowledge Base
    Replies: 0
    Last Post: 09-25-2002, 12:02 PM

Posting Permissions

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