Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Mar 2002
    Location
    Germany, Germany
    Posts
    169
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Keep focus on cell (XP SP3)

    Hello everybody,

    I have a worksheet, where I want to display some additional information for specific cells as soon as these cells are selected (see attached workbook). Therefore, I use the "Worksheet_SelectionChange"-event. The only problem is, that the userform takes the focus and I do not find a way to give it back to the selected cell. I need to set the mouse pointer to another cell by using the mouse. I would prefer to still be enabled to use the arrow-keys. Is there a way to give to focus back to the worksheet or to prevent the userform getting the focus?
    Any help will be highly appreciated!
    Attached Files Attached Files

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Keep focus on cell (XP SP3)

    Insert the line

    AppActivate "Microsoft Excel"

    immediately below the line mfrmInfo.Show (above End If).

  3. #3
    2 Star Lounger
    Join Date
    Mar 2002
    Location
    Germany, Germany
    Posts
    169
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Keep focus on cell (XP SP3)

    Hello Hans,

    solutions can be so simple...

    Thank you very much for this idea, it works perfectly!

Posting Permissions

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