Article View: borland.public.cppbuilder.nativeapi
Article #10398Re: FileExists() is using wildcards
From: Remy Lebeau (TeamB)
Date: Tue, 27 Apr 2004 15:29
Date: Tue, 27 Apr 2004 15:29
29 lines
2253 bytes
2253 bytes
"Hans Galema" <dontusethis@dontusethis.nl> wrote in message news:408e2856$1@newsgroups.borland.com... > So it does support wildcards. Not intentionally. Borland probably just did not pay enough attention to how FileFirstFile() actually works when they were designing the FileAge() function, without realizing the side effect that would be introduced. > The allowing of wildcards was unexpected behaviour for me. > My own file_exist() function (as shown in my first post) has > expected behaviour. Only beause you were forcing the file system to actually open a file, which can't be done with wildcards present. Physically opening the file is not necessarily the best way to test for a file's existance, though, because there are many reasons why opening a file could fail even though the file does actually exist, so you would be returning an inaccurate return value. > Heee. There is nothing buggy in my code that generates > the filename. It nicely places '?'s on occasions. I would consider it buggy if it were producing a filename that you expected to have a particular behavior but actually had a different undesirable behavior instead. Gambit
Technical Details
Message-ID:
<408e7db0$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<408d6cad$1@newsgroups.borland.com> <408d8056$1@newsgroups.borland.com> <408e0d6a$1@newsgroups.borland.com> <408e1c4a$1@newsgroups.borland.com> <408e2856$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,8374fb71f8a662f4 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2004-04-27 08:40:21 PST From: "Remy Lebeau \(TeamB\)" <gambit47.no.spam@no.spam.yahoo.com> Newsgroups: borland.public.cppbuilder.nativeapi References: <408d6cad$1@newsgroups.borland.com> <408d8056$1@newsgroups.borland.com> <408e0d6a$1@newsgroups.borland.com> <408e1c4a$1@newsgroups.borland.com> <408e2856$1@newsgroups.borland.com> Subject: Re: FileExists() is using wildcards Date: Tue, 27 Apr 2004 08:29:07 -0700 Lines: 31 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 NNTP-Posting-Host: 67.22.138.253 Message-ID: <408e7db0$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1083080112 67.22.138.253 (27 Apr 2004 08:35:12 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail