View Full Version : Find file and assign it's path to string?
clhare
08-25-2011, 05:04 AM
I need to find a specific file and then assign the path of that file to a string but I have no idea where to start! Can someone help?
Thanks!
Frosty
08-25-2011, 05:44 PM
I assume my previous response to a very similar thread by you didn't help?
Maybe this will help, as it details some Windows API calls you can use too.
http://support.microsoft.com/kb/185476
I personally have not used those calls, but I've never needed to program a really robust custom search feature in VBA.
Without anything more than a one line sentence, it's really tough to know how to help without simply programming the whole thing for you. As I mentioned in the other thread... this kind of open file search could take a long time if you just say "it's somewhere on my hard drive or somewhere on one of my connected network drives."
There are many ways to approach such a broad concept of "I need to find a specific file"... you need to narrow it down before you'll get much of an answer.
The easiest way, I think, would be for your end-user to provide a folder to search in... and then simply use the FileSystemObject. But as I posted sample code about that in another thread... you need to try and be more specific.
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.