View Full Version : TRUE if Exist Directory
Option_Explicit
03-07-2003, 07:00 PM
How would you go about setting a variable to check if a FOLDER exists,(not file)
Return TRUE if exists??
Corey
03-07-2003, 07:04 PM
Although there is no main way it's super easy to just check for a file in that folder. /ubbthreads/images/icons/smile.gif So for example check for c:\windows\desktop\myfolder\myfolder.txt or whatever, if it doesn't exist then neither does the folder... Just one workaround...
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Option_Explicit
03-07-2003, 07:26 PM
thats what I'm using now as a workaround, I figured there would have been a better way, What would the code to "GetInformation.File = TRUE if Exists" look like? could I expand off that somehow? or like always....wait for Worm to do it?
Corey
03-07-2003, 07:50 PM
Not sure what you're talking about...
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Option_Explicit
03-07-2003, 07:58 PM
.File\GetInformation\Action Properties\Existence("TRUE" if file exists)
If I used this action to check for a file, could this action not be modified for Folder instead?
Corey
03-07-2003, 08:37 PM
No idea...
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
I've come across this myself. I ended up writing a DLL to take care of it.
Pick it up here (http://www.warmuskerken.com/ams/folderexist.zip)
Corey
03-07-2003, 09:15 PM
Cool .dll Worm. It would be nice to have a bunch more folder functions no doubt, i.e. find, rename, move, copy, etc...
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Option_Explicit
03-07-2003, 09:25 PM
Worm does it again!!! , I'll incorporate this dll into some test projects...get the feel for it, but it looks good so far.
Where would I also find the functions for the "GetFolders.dll"
All I needed was to know if a folder existed, so thats all I wrote. If you have some ideas, pass them on and I'll see what I can come up with. No promises though, I'm still fairly new to C++ and its a complex language/ubbthreads/images/icons/crazy.gif
Corey
03-07-2003, 09:39 PM
No I didn't mean from you, I meant in AMS 5. Although... /ubbthreads/images/icons/smile.gif
C++ is awesome, way too boring for someone like me but awesome for sure. I'm sure your brain gets used to it after a while. /ubbthreads/images/icons/smile.gif
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Corey
03-07-2003, 09:59 PM
BTW Worm I'd just like to give you a massive thank you from the entire IR team for the coolness you share. Your efforts are always noticed and never taken for granted.
Corey Milner
Creative Director, Indigo Rose Software (http://www.indigorose.com)
Thanks for the nod Corey, I appreciate it.
Powered by vBulletin™ Version 4.0.6 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.