954,500 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Listing files in a directory

Hi,
Does anyone know how i could get a list of all files in a given directory given the directory's path using c++?

crazybitez
Newbie Poster
8 posts since Jul 2004
Reputation Points: 10
Solved Threads: 0
 

Hello,

This could be OS dependant. In C++, programming on a Mac, you would make an API call to the OS to build the dialogue box, and then the files would be populated within. I am sure Windoze has similar functionality.

What OS are you building / programming for?

Let us know.

Christian

kc0arf
Posting Virtuoso
Team Colleague
1,937 posts since Mar 2004
Reputation Points: 121
Solved Threads: 57
 
Does anyone know how i could get a list of all files in a given directory given the directory's path using c++?

http://faq.cprogramming.com/cgi-bin/smartfaq.cgi?answer=1046380353&id=1044780608

Dave Sinkula
long time no c
Team Colleague
5,058 posts since Apr 2004
Reputation Points: 2,780
Solved Threads: 314
 

I am planning to use Linux...(g++ compiler..)...i know about the c part of it but is there something for c++?

crazybitez
Newbie Poster
8 posts since Jul 2004
Reputation Points: 10
Solved Threads: 0
 
Ashishinani1756
Newbie Poster
10 posts since Sep 2009
Reputation Points: 3
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You