Linux Folder Iteration

C

Connell

Hi,

Sorry if this is OT but I'm not sure where else to post it.

How do you iterate through the files in a particular folder on linux in
C++?

Thanks,
Connell
 
R

red floyd

[OFF-TOPIC]
[PEDANTIC]
Linux has "directories", not "folders".
[/PEDANTIC]
[/OFF-TOPIC]
 
?

=?ISO-8859-1?Q?Sch=FCle_Daniel?=

Connell said:
Hi,

Sorry if this is OT but I'm not sure where else to post it.

How do you iterate through the files in a particular folder on linux in
C++?

Thanks,
Connell

look for opendir, readdir in google or
man opendir

hth, Daniel
 
D

Dietmar Kuehl

Connell said:
Sorry if this is OT but I'm not sure where else to post it.

Well, as is, the question is clearly off-topic because it is
environment specific. There is, however, a fairly general answer:
How do you iterate through the files in a particular folder on linux in
C++?

The Boost file system library provides functionality like this. As
this library will likely become part of the second C++ library
technical report (TR2 for short), it has a fair chance to eventually
become part of the standard C++ library. Just get the library from
<http://www.boost.org/>.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,677
Members
48,796
Latest member
Greg L.

Latest Threads

Top