Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Alex Mackenzie
 
Posts: n/a
Default Widening Validation Box

I have found an earlier reference on how to temporarily widen a validation
box using target.columns.columnwidth. Is there a way I can do this ONLY when
a specific validation box is being used, i.e. I do not want to temporarily
widen the column every time a cell is active, only one or two cells. Thank
you
  #2   Report Post  
Bob Phillips
 
Posts: n/a
Default Widening Validation Box

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
With Target
If .Count 1 Then Exit Sub
If .Address = "$B$5" Or .Address = "$H$8" Then
.Columns.ColumnWidth = 20
Else
Columns(2).ColumnWidth = 5
Columns(8).ColumnWidth = 5
End If
End With
End Sub


'This is worksheet event code, which means that it needs to be
'placed in the appropriate worksheet code module, not a standard
'code module. To do this, right-click on the sheet tab, select
'the View Code option from the menu, and paste the code in.


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Alex Mackenzie" wrote in message
...
I have found an earlier reference on how to temporarily widen a validation
box using target.columns.columnwidth. Is there a way I can do this ONLY

when
a specific validation box is being used, i.e. I do not want to temporarily
widen the column every time a cell is active, only one or two cells.

Thank
you



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
Case Sensitivity problem with data validation Upya Excel Worksheet Functions 3 October 7th 05 01:30 AM
TWO QUESTIONS: Validation & Spacing...PLEASE HELP Polina Excel Discussion (Misc queries) 3 July 29th 05 02:36 AM
data validation lists [email protected] Excel Discussion (Misc queries) 5 June 25th 05 07:44 PM
named range, data validation: list non-selected items, and new added items KR Excel Discussion (Misc queries) 1 June 24th 05 05:21 AM
Data Validation Window? Ken Excel Discussion (Misc queries) 1 January 11th 05 10:48 PM


All times are GMT +1. The time now is 05:37 PM.

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

About Us

"It's about Microsoft Excel"