Data validation list by letter

Cam40933

New Member
Joined
Sep 14, 2011
Messages
1
I have used Data validation in excel to create a list of Car vehicles. I would however like to type in the first letter of the vehicle and the list to go to the vehicles beginning with this letter. I have so many vehicles it would save so much time scrolling up and down.

Your answers would be much appreciated.
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
You could easily just use autofilter, click "Custom"

rule is Begin with "Letter"

click "ok"

Done.

Again the same feature could be done in VBA so that you could enter "letter" into a cell and the list populate with that letter easily.

I hope that helps.
 
Upvote 0
One option:-
Change "B1" in code to Validation cell address.
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Dim rng As Range
Dim Dn As Range
If Target.Address(0, 0) = "B1" And Len(Target) = 1 Then
  Set rng = Range(Mid$(Range("B1").Validation.Formula1, 3, Len(Range("B1").Validation.Formula1) - 2))
For Each Dn In rng
    If Left$(Dn, 1) = Target Then Target = Dn
Next Dn
  End If
End Sub
Mick
 
Upvote 0

Forum statistics

Threads
1,224,600
Messages
6,179,836
Members
452,947
Latest member
Gerry_F

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top