K
kirkm
Hi
I got this code example form Excel Help
--
With Worksheets(1).Range("a1:a500")
Set c = .Find(2, LookIn:=xlValues)
If Not c Is Nothing Then
firstAddress = c.Address
Do
c.Value = 5
Set c = .FindNext(c)
Loop While Not c Is Nothing And c.Address <> firstAddress
End If
End With
--
I know this finds the value 2 and changes it to 5. Could this
be changed so it finds either 2 OR 3 ?
I don't need to change anything to 5, just want to build an
array of row numbers where there's 2 or 5.
(The 2 and 5 here are examples, eventually I want to find any two
strings with this method).
Thanks for any help.
Cheers - Kirk
I got this code example form Excel Help
--
With Worksheets(1).Range("a1:a500")
Set c = .Find(2, LookIn:=xlValues)
If Not c Is Nothing Then
firstAddress = c.Address
Do
c.Value = 5
Set c = .FindNext(c)
Loop While Not c Is Nothing And c.Address <> firstAddress
End If
End With
--
I know this finds the value 2 and changes it to 5. Could this
be changed so it finds either 2 OR 3 ?
I don't need to change anything to 5, just want to build an
array of row numbers where there's 2 or 5.
(The 2 and 5 here are examples, eventually I want to find any two
strings with this method).
Thanks for any help.
Cheers - Kirk