Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 300
Default After checking control checkbox returning focus to the sheet

After a user has checked a control checkbox, the focus normally remains on
the control. I don't like this. Now to return the focus to the sheet I'm
using:

ActiveWindow.RangeSelection.Select

But this is less than perfect. If the active cell is not in view, the
spreadsheet will jump to put it in view. Is there some other way I can
return the focus to the sheet without this quirk?

Thanks, Don <donwiss at panix.com.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default After checking control checkbox returning focus to the sheet

ActiveSheet.Range("A1").Selec

--
Message posted from http://www.ExcelForum.com

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default After checking control checkbox returning focus to the sheet

Sorry, this is what you really want :-

ActiveWindow.VisibleRange.Cells(1, 1).Selec

--
Message posted from http://www.ExcelForum.com

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 50
Default After checking control checkbox returning focus to the sheet

The checkboxes from the Forms toolbar don't take focus when clicked.
But if you must use the ActiveX checkbox, try the following.

Private Sub CheckBox1_Click()
SendKeys "{ESC}"
End Sub


Regards,
Vic Eldridge



Don Wiss wrote in message . ..
After a user has checked a control checkbox, the focus normally remains on
the control. I don't like this. Now to return the focus to the sheet I'm
using:

ActiveWindow.RangeSelection.Select

But this is less than perfect. If the active cell is not in view, the
spreadsheet will jump to put it in view. Is there some other way I can
return the focus to the sheet without this quirk?

Thanks, Don <donwiss at panix.com.

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
font size changes w/ control focus mark kubicki Excel Worksheet Functions 0 June 17th 05 06:00 PM
Focus on Control before UserForm(s) pop up Bob Phillips[_6_] Excel Programming 0 May 5th 04 04:03 PM
test if a control has or doesnt have focus? John T Ingato Excel Programming 0 November 11th 03 04:37 PM
Taking focus off a Control Checkbox Don Wiss Excel Programming 1 November 11th 03 12:18 AM
Returning Key Focus Dan Gesshel Excel Programming 1 September 5th 03 07:14 PM


All times are GMT +1. The time now is 12:56 AM.

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"