I did some testing and also found out that both DirExists and isDir return True for an empty string. A workaround for this isssue is to use FileExists which works well with both files and directories. FileExists correctly returns False if used with an empty string. : I'm finding that DirExists returns a TRUE value when provided an : empty string, contradictory to what the documentation says. : Can you verify this? : I'm running vers.3.2.3 : Excerpt from the documentation: Return value: Boolean. Returns True if the : directory exists directory and False otherwise. : DirExists statement also returns False if dir is an invalid name or an empty : string.
|