ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Search for 6 Character value (https://www.excelbanter.com/excel-discussion-misc-queries/168034-search-6-character-value.html)

MFINE

Search for 6 Character value
 
Hi, I am trying to design a macro that will search for values in a column
that are 6 characters long. Data is text that looks like numbers (downloaded
from a mainframe). I tried using a search with 6 *'s but it just returned
everything.

Any suggestions?

Thanks

Marc

Dave Peterson

Search for 6 Character value
 
How about searching for ?????? (6 question marks)
* means any set of characters
? a single character

Make sure you specify lookat:=xlwhole in your code.



MFINE wrote:

Hi, I am trying to design a macro that will search for values in a column
that are 6 characters long. Data is text that looks like numbers (downloaded
from a mainframe). I tried using a search with 6 *'s but it just returned
everything.

Any suggestions?

Thanks

Marc


--

Dave Peterson

MFINE

Search for 6 Character value
 
Duhhhhhh. I can tell this has been a long week. Thanks

Marc

"Dave Peterson" wrote:

How about searching for ?????? (6 question marks)
* means any set of characters
? a single character

Make sure you specify lookat:=xlwhole in your code.



MFINE wrote:

Hi, I am trying to design a macro that will search for values in a column
that are 6 characters long. Data is text that looks like numbers (downloaded
from a mainframe). I tried using a search with 6 *'s but it just returned
everything.

Any suggestions?

Thanks

Marc


--

Dave Peterson



All times are GMT +1. The time now is 01:00 AM.

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