Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 33
Default Trouble with Focus

Hi,

I'm struggling with a sheet which has a selected row (which I want to
maintain for user visibility).

When the user selects a textbox control on the worksheet (configured to work
like a button using mousedown event), I wish it to perform a function, but
to maintain the row selection on the sheet after it has completed.

It seems that event with all the other functions disabled, selecting the
worksheet control causes a change in focus from the worksheet, and the range
selection is lost. (An cannot be reset without returning the focus to the
worksheet first?

Any help would be appreciated.
XL2000 on Windows 2000 Pro

Regards,

Alex@JPCS


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 109
Default Trouble with Focus

Sub test()
Dim MyRange As Range
Set MyRange = Selection
'- run code
MyRange.Select
End Sub

Regards
BrianB
================================================== ===




"Alex@JPCS" wrote in message ...
Hi,

I'm struggling with a sheet which has a selected row (which I want to
maintain for user visibility).

When the user selects a textbox control on the worksheet (configured to work
like a button using mousedown event), I wish it to perform a function, but
to maintain the row selection on the sheet after it has completed.

It seems that event with all the other functions disabled, selecting the
worksheet control causes a change in focus from the worksheet, and the range
selection is lost. (An cannot be reset without returning the focus to the
worksheet first?

Any help would be appreciated.
XL2000 on Windows 2000 Pro

Regards,

Alex@JPCS

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
COMBO BOX FOCUS -debi- Excel Worksheet Functions 0 July 18th 08 03:07 PM
Setting the focus Orf Bartrop New Users to Excel 4 August 9th 06 05:36 AM
focus Capp Excel Discussion (Misc queries) 2 November 18th 05 07:25 PM
set focus tkaplan Excel Discussion (Misc queries) 3 September 27th 05 07:41 PM
Focus David Unger Excel Worksheet Functions 20 March 21st 05 06:43 PM


All times are GMT +1. The time now is 01:52 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"