ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Filesearch with disregard of Case (https://www.excelbanter.com/excel-programming/304022-filesearch-disregard-case.html)

Michael Singmin

Filesearch with disregard of Case
 
Hello group,

I am using Application.Filsearch to look for text
I want the Filesearch not to look at Case.
So Cat, cAT and caT will be found if .TextOrProperty = "Cat"
I have set .MatchTextExactly = False

But something is still not right because only Cat is found.

Any insights ?

Michael Singmin



NickHK

Filesearch with disregard of Case
 
Michael,
You code functions correctly for me. What is the value of .FoundFiles.Count
that is returned ?

NickHK

"Michael Singmin" wrote in message
...
Hello group,

I am using Application.Filsearch to look for text
I want the Filesearch not to look at Case.
So Cat, cAT and caT will be found if .TextOrProperty = "Cat"
I have set .MatchTextExactly = False

But something is still not right because only Cat is found.

Any insights ?

Michael Singmin





keepITcool

Filesearch with disregard of Case
 
please note that
matchtextexactly

is NOT releated to the filenames but to the search of filecontents

from help:

MatchTextExactly Property
See Also Applies To Example Specifics
Some of the content in this topic may not be applicable to some
languages.

True if the specified file search will find only files whose body text
or file properties contain the exact word or phrase that you've
specified. Read/write Boolean.



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


Michael Singmin wrote:

Hello group,

I am using Application.Filsearch to look for text
I want the Filesearch not to look at Case.
So Cat, cAT and caT will be found if .TextOrProperty = "Cat"
I have set .MatchTextExactly = False

But something is still not right because only Cat is found.

Any insights ?

Michael Singmin






All times are GMT +1. The time now is 08:25 PM.

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