+ Reply to Thread
Results 1 to 2 of 2

Mimic keystrokes?

  1. #1
    Targus
    Guest

    Mimic keystrokes?

    Hi,

    Does anyone know how to mimic keystrokes and/or mouse movements using
    VBA??

    I'm writing a macro that uses a macro written by someone else. I do
    not have access to their code, so I can't see what is happening on
    their end. When their code is run, a file path box opens twice, and
    each time a user has to manually press the 'cancel' button on the file
    path box. I want to have my VBA code press the 'cancel' button or
    press the 'escape' key twice to mimic a user clicking a mouse or
    pressing 'escape' to ignore the file path box.

    Any suggestions ??


  2. #2
    RB Smissaert
    Guest

    Re: Mimic keystrokes?

    You could try any of these 2 lines, but the result will be totally
    unpredictable.

    SendKeys "{ESC},2", True
    SendKeys "{ESC},2", False

    RBS

    "Targus" <[email protected]> wrote in message
    news:[email protected]...
    > Hi,
    >
    > Does anyone know how to mimic keystrokes and/or mouse movements using
    > VBA??
    >
    > I'm writing a macro that uses a macro written by someone else. I do
    > not have access to their code, so I can't see what is happening on
    > their end. When their code is run, a file path box opens twice, and
    > each time a user has to manually press the 'cancel' button on the file
    > path box. I want to have my VBA code press the 'cancel' button or
    > press the 'escape' key twice to mimic a user clicking a mouse or
    > pressing 'escape' to ignore the file path box.
    >
    > Any suggestions ??
    >



+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1