LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 62
Default Making data validation drop down list wider

My VB is very weak (trying to learn). I've followed the instructions on
Debra Dalgleish's site for adding code to the worksheet and it works fine for
a single column but I don't know how to change the code when I have multiple
columns that need to be temporarily widened so that you can see the entire
selection in the drop down list.

My worksheet code looks like:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Count 1 Then Exit Sub
If Target.Column = 13 Then
Target.Columns.ColumnWidth = 18
Else
Columns(13).ColumnWidth = 15.38
End If
End Sub

'Private Sub Worksheet_SelectionChange(ByVal Target As Range)
' If Target.Count 1 Then Exit Sub
' If Target.Column = 3 Then
' Target.Columns.ColumnWidth = 28
' Else
' Columns(3).ColumnWidth = 21
' End If
'End Sub

I have 10+ columns of drop downs that are too wide to view in the
spreadsheet (I have the columns formatted to wordwrap so that the sheet isn't
too wide to be usable when completed).

How do I need to modify the code for the extra columns?

Thanks,
 
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
data validation mattdsc Excel Worksheet Functions 4 July 26th 06 11:30 AM
Data Validation in Excel - drop down list font size Mikeytj Excel Discussion (Misc queries) 3 March 9th 06 08:35 PM
Dependent List (via Data Validation) Error Dezdan Excel Worksheet Functions 2 December 2nd 05 12:33 AM
Excel Macro to Copy & Paste [email protected] Excel Worksheet Functions 0 December 1st 05 01:56 PM
Expanding Data validation from List mark hansen Excel Discussion (Misc queries) 2 September 4th 05 01:39 AM


All times are GMT +1. The time now is 09:03 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"