ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   FileSearch for a TextorProperty with a wildcard (https://www.excelbanter.com/excel-programming/284940-filesearch-textorproperty-wildcard.html)

myensr

FileSearch for a TextorProperty with a wildcard
 
I'm trying to search through files and return the filenames of those files that contain a particular text. Well, I can do this just find if I know exactly the text I'm looking for but I don't. (I only know for certain the last 8 characters of a 14 character string). I've tried wildcards and setting .MatchTextExactly = False, but I still can't get this to work. Does anyone have any advice that could help me out with this? Much appreciated



BrianB

FileSearch for a TextorProperty with a wildcard
 
Have a look at the VB Instr() function which will allow you to search
for your 8 characters. If it returns a number more than zero
...........


Regards
BrianB
================================================== ============

myensr wrote in message ...
I'm trying to search through files and return the filenames of those

files that contain a particular text. Well, I can do this just find if
I know exactly the text I'm looking for but I don't. (I only know for
certain the last 8 characters of a 14 character string). I've tried
wildcards and setting .MatchTextExactly = False, but I still can't get
this to work. Does anyone have any advice that could help me out with
this? Much appreciated.


All times are GMT +1. The time now is 05:07 PM.

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