Message-ID: <3924B7F6.28989BA7@gtcom.net> From: Krogg X-Mailer: Mozilla 4.61 [en] (Win95; U) X-Accept-Language: en,en-US,en-GB,ja,af MIME-Version: 1.0 Newsgroups: comp.os.msdos.djgpp Subject: Re: Directory listing References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 31 Date: Thu, 18 May 2000 23:41:42 -0400 NNTP-Posting-Host: 12.16.179.119 X-Trace: eagle.america.net 958707787 12.16.179.119 (Thu, 18 May 2000 23:43:07 EDT) NNTP-Posting-Date: Thu, 18 May 2000 23:43:07 EDT Organization: 24hoursupport.com To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Eli Zaretskii wrote: > > On Wed, 17 May 2000, Krogg wrote: > > > What i want in the listing is all files that match "*.c" > > and the names of the subdirectories.... > > > > here is my sample code...how can i change it to > > print out the subdirectories and the "*.c" files? > > Pass "*.*" to findfirst, then use the fnmatch function to filter the > files which match the "*.c" pattern. I can just use "*.c" in the findfirst function and get the same result.But lets say i uses "*.*" and filtered the list with fnmatch.... How do i filter subdirectories from the list? I cant look for ones without dots in the name,cause there may be some files without dots and it would not catch "." and ".." IS there a good way to get a list of subdirectories in the current directory? -- Krogg