Find exact match.
When you do a find it is best to specify all of the settings as the find
function just uses whatever the last used settings were. So oddly enough your
code will work sometimes. Here is what you should have...
Set C = .Find(What:=Priority, _
LookIn:=xlValues, _
LookAt:=xlWhole, _
MatchCase:=True)
--
HTH...
Jim Thomlinson
" wrote:
I have a visual basic macro with the following line.
Set C = .Find(Priority, LookIn:=xlValues)
The problem is that if priority = 1, I might get back the column that
has 13 is there any easy way to find an exact match?
|