#1
|
|||
|
|||
Toggle Button takes focus and thus changes selection
Hi to all,
I'm using an ActiveX toggle button in one of my documents. The problem is: toggle buttons do not have a TakeFocusOnClick = False property like command buttons do. So clicking the toggle button means a selection change, but I'd like to continue working at (former) cursor position. Application.GoBack at the end of the tgl_Click procedure does not work the way it should (for my purpose). I even tried an app_WindowSelectionChange event, but I simply did not succeed in saving the selection.range before clicking the toggle button. Do you have an idea? Any help appreciated ... thanks NP |
#2
|
|||
|
|||
Code:
If Selection.Range.InlineShapes.Count > 0 Then If Not Selection.Range.InlineShapes(1).Type = 5 Then RSel = Selection.Range Else Set RSel = Selection.Range End If Cheers NP |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Toggle Button | Squibble | Word VBA | 2 | 06-11-2014 05:36 PM |
Circling your selection on word vs check box or radio button | NBuckley | Word | 2 | 04-04-2014 03:17 AM |
Selection of all Text for a specific page in word is spanning selection across pages | ramsgarla | Word VBA | 9 | 12-05-2012 03:23 AM |
MS WORD takes forever to open .. | dflockyer | Word | 2 | 06-25-2012 05:24 PM |
mail merge takes and age | williebear | Outlook | 1 | 05-27-2009 11:32 PM |