Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.FileSearch crashed Excel in Windows 2K
I use the following code to search for specific files:
MyFilePath = "C:\Documents and Settings\trinaj\My Documents\" ' This is for 'trinaj's computer MarkSub "starting filesearch next:FindOldFiles" With Application.FileSearch .NewSearch .FileName = "*.xls" .LookIn = MyFilePath .SearchSubFolders = True .TextOrProperty = "BuildStreetsReports" .MatchTextExactly = False .Execute MarkSub "filesearch complete:FindOldFiles" =========================== This code runs fine on a Windows 98 system (though it is slow) and runs fine on a Windows XP system (very quick). I tried to read the path to the user's "My documents" folder, but settled for hard coding in that for this user (trinaj). I had the user open a worksheet that read that and recorded it and then had he send me the worksheet. Then I had her browse to her My Docs folder and copy the path and email it to me. I got the same path each time (C:\Documents and Settings\trinaj\My Documents\), so I am fairly assured that this is correct. MarkSub records the passed text in an extra worksheet and saves the workbook, and when I look at that sheet, "starting filesearch next:FindOldFiles" is the last entry, so I think I can be certain that the "Application.FileSearch" is where things bomb. Can anyone suggest a solution? Possibly an alternative to using "Application.FileSearch". This needs to be generic enough that I don't have to have each user do any unusual configuration to make it work. The multitude of users have Windows 98, Windows 2K and Windows XP. TIA, Ken |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Application.FileSearch | Excel Discussion (Misc queries) | |||
Application.FileSearch is not working?? | Excel Programming | |||
Application.Filesearch yields incorrect results?? | Excel Programming | |||
FileSearch inconsistencies between Office/Windows version combinat | Excel Programming | |||
VBA Application.FileSearch | Excel Programming |