accessing LINUX directory tree using C++

DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: accessing LINUX directory tree using C++

  1. #1
    Join Date
    Mar 2007

    accessing LINUX directory tree using C++

    I work on LINUX. I've a directory (say root_dir=/home) and many sub-directories inside it. Using C++, I want to get all those sub-directories name as unicode string and store them in a list data structure provided by the c++.
    can some suggest how to proceed.

    thank u

  2. #2
    Join Date
    Nov 2003
    you can use the dirent library to traverse the current directory and obtain more inforabout each file (e.g., whether the current file is actually a directory):
    You can then store the results in a standard container such as std::list.
    Danny Kalev

Similar Threads

  1. Replies: 6
    Last Post: 09-06-2005, 04:53 PM
  2. Replies: 0
    Last Post: 07-21-2003, 02:17 PM
  3. Directory tree
    By Keith in forum ASP.NET
    Replies: 1
    Last Post: 09-04-2002, 12:16 PM
  4. My view of the world
    By Kevin Moore in forum .NET
    Replies: 55
    Last Post: 02-27-2002, 03:06 PM
  5. accessing a DOM tree element
    By joe crew in forum XML
    Replies: 0
    Last Post: 04-26-2001, 12:27 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center