ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   find (exact match) ? (https://www.excelbanter.com/excel-programming/318504-find-exact-match.html)

Mark Kubicki

find (exact match) ?
 
i'm using the statement:
Set c = .Find(What:=Range("B" & CStr(r)).Value,
LookIn:=xlValues)

however, as an example, if the value i'm looking for is "Macklowe
Residence", the result is being returned at the first instance of "Macklowe"
(such as: "Linda Macklowe Residence");

i need to the search to find the exact match (Linda is Mr. Macklowe's mom,
and we did a small project for her in the middle of the Macklowe Residence
Project !!, not to confuse the 2...)

thanks in advance, mark



Tom Ogilvy

find (exact match) ?
 
Set c = .Find(What:=Range("B" & CStr(r)).Value, _
LookIn:=xlValues, Lookat:=xlWhole)

--
Regards,
Tom Ogilvy

"mark kubicki" wrote in message
...
i'm using the statement:
Set c = .Find(What:=Range("B" & CStr(r)).Value,
LookIn:=xlValues)

however, as an example, if the value i'm looking for is "Macklowe
Residence", the result is being returned at the first instance of

"Macklowe"
(such as: "Linda Macklowe Residence");

i need to the search to find the exact match (Linda is Mr. Macklowe's mom,
and we did a small project for her in the middle of the Macklowe Residence
Project !!, not to confuse the 2...)

thanks in advance, mark






All times are GMT +1. The time now is 04:44 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com