Boy, it's been a while since I've used those handy functions on DOS :)
I don't know of direct equivalent on System i, but being that list is kind
of quiet today...
Closest fit is probably opendir(), readdir(), closedir().  You might also
need to use stat() or fstat() to get additional information on the files.
You can probably code up wrapper functions that would fully imitate DOS
functions, but I wouldn't do it unless you're porting an existing

There is a simple example at the bottom of this link:


-----Original Message-----
Subject: [C400-L] _dos_findfirst and _dos_findnext analog on AS/400

I remember, there was a fine set of C functions on PC:
_dos_findfirst and _dos_findnext. Names slightly differ from compiler to

With their help it was very easy to process set of files with names,
matching certain criteria.

Is there anything similar in ILE/C to process files, that reside in IFS

Stupid ideas come to mind, like sending directory listing to file....

Any advise will be highly appreciated,

Jevgeni Astanovski

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 by and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].