Dear all:
I'm trying to use "find" command to search a particular word (460V, 230V etc..) in a SPECIFIC cell. The cell is under row "R". It will identify the string when the argument is satisfied. Here is what I did:
With Worksheets("Import").Range("R1:R500")
Set Dummy2 = .Find("230v", LookIn:=xlValues)
If Not Dummy2 Is Nothing Then
VOLT = "230V"
Else
Set Dummy2 = .Find("208v", LookIn:=xlValues)
If Not Dummy2 Is Nothing Then
VOLT = "208V"
Else
Set Dummy2 = .Find("460v", LookIn:=xlValues)
If Not Dummy2 Is Nothing Then
VOLT = "460V"
Else
Set Dummy2 = .Find("380v", LookIn:=xlValues)
If Not Dummy2 Is Nothing Then
VOLT = "380V"
Else
VOLT = "TBD VOLTAGE"
The problem is the command shows above will search all cells in row "R". Some time there will be conflict because there will be a situation when one cell showing "480V" while other cell showing "380V". The cell that has "380V" is actually the cell that I will like my program to seach on. How can I modify my command so it will search on a specific cell. You help is much appreciated.
Best Regards
Howard
Bookmarks