search function

G

Gary

I have a list of 500 movies and i want to have a "search" box to search my
list for a specific movie by entering a partcial name.
 
F

FSt1

hi
Ctrl+f will bring up the find box.
or click on the icon that looks like a pair of binoculars.
or on the 2003 menu bar....
edit>find.

regards
FSt1
 
J

JLGWhiz

You could get more than one movie that way, but try this. Assuming the
movie name is "Casablanca" and the list is in column A.

Sub getit()
lr = ActiveSheet.Cells(Rows.Count, 1).End(xlUp).Row
Set rng = Range("A2:A" & lr)
For Each c In rng
If c.Value Like "*blanc*" Then
MsgBox "The movie is " & c.Value
Exit For
End If
Next
End Sub
 
Top