View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default what is the best way to find a value in a sheet in VBA?

Easiest is to just try it, but there aren't significantly faster ways. It
should only look at Used cells, not the entire column, I would think - at
least it is fast enough to indicate that - no way to prove it.

--
Regards,
Tom Ogilvy



"serdar" wrote in message
...
if i look up to some columns with:

Columns("A:D").Find(x, LookIn:=xlValues)

,does this looks "all" rows in columns a to d, or just the formatted ones?
If first is true, does this takes too much time than looking up by giving
the actual workspace as a range(not a good solution for me)?

thanks.


"Tom Ogilvy" , haber iletisinde şunları
...
It is the most general way if you don't want to loop.

You can also use the built in lookup, vlookup, match type functions.

--
Regards,
Tom Ogilvy


"serdar" wrote in message
...
.Find(x, LookIn:=xlValues)

Is this the only way?