sizing in Drop Down lists

B

Banker

I have attached drop down lists to a cell on my worksheet. The items in the
list are wider than the cell that it will be viewed in. I know I can format
the actual cell to wrap the text if it needs to for viewing after selected
but how can I VIEW the entire width needed in the drop down list when I click
on the arrow to choose the item I wish to show?? Basically I can only read
about half of each of the items in the list. I hope this makes sense.
 
B

Banker

Sorry T. Valko, When I pull up your response the screen is blank. Can you
please try again???
 
G

Gord Dibben

Debra Dalgleish has written event code to temporarily widen the column when
the DV dropdown is selected.

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Count > 1 Then Exit Sub
If Target.Column = 4 Then
Target.Columns.ColumnWidth = 20
Else
Columns(4).ColumnWidth = 8.43
End If
End Sub

Assumes DV dropdowns are in column D. If you want a specific or reduced
range post back.

This is sheet event code. Right-click on the sheet tab and "View Code"

Copy/paste the above into that module. Alt + q to return to the Excel
window.


Gord Dibben MS Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top