| delorie.com/archives/browse.cgi | search |
| Message-Id: | <3.0.6.32.19990728155751.00859240@dce03.ipt.br> |
| X-Sender: | csrabak AT dce03 DOT ipt DOT br |
| X-Mailer: | QUALCOMM Windows Eudora Light Version 3.0.6 (32) |
| Date: | Wed, 28 Jul 1999 15:57:51 -0300 |
| To: | djgpp AT delorie DOT com |
| From: | "Cesar S. Rabak" <csrabak AT ipt DOT br> |
| Subject: | Re: getting all filename in sub-directory |
| In-Reply-To: | <Pine.SUN.3.91.990728133021.26762E-100000@is> |
| References: | <933148163 DOT 6501 AT www DOT remarq DOT com> |
| Mime-Version: | 1.0 |
| Reply-To: | djgpp AT delorie DOT com |
| X-Mailing-List: | djgpp AT delorie DOT com |
| X-Unsubscribes-To: | listserv AT delorie DOT com |
At 13:31 28/07/99 +0300, you wrote:
>
>On Tue, 27 Jul 1999, Clemens Valens wrote:
>
>> About your system() command, you could do it as
>>
>> char show_files[] = "dir *.exe /s > exe_files.txt";
>> system(show_files);
>
>Or, even better:
>
> FILE *fp = popen ("dir *.exe /s", "rt");
> fread (fp, ...);
>
Eli, but in this case the popen would prefer to use the "dir.exe" in
DJGPP/BIN, wouldn't?
If so, it will not honor the /s switch, but write in fp, something like "No
/s: no such file or directory (ENOENT).
Cesar
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |