Thread: Directory/File info

  1. #1
    Anonymous
    Guest

    Smile Directory/File info

    How do I get a list of all files/directories in a specified directory (Eg. "/home") using C++ header files/namespaces and not C header files?

  2. #2
    muttski
    Guest
    I dont understand, why no C headers?

  3. #3
    The Artful Lurker Deckard's Avatar
    Join Date
    Jan 2002
    Posts
    633
    Hmm, this is such an odd request that I suspect it originated from a teacher or a junior V.P. Either way, you should be able to make use of the system() library function by including iostream.h.
    Code:
    system( "ls /home" );
    HTH
    Jason Deckard

  4. #4
    muttski
    Guest
    Maybey, but I thought system was in stdlib and thats C, maybey its in both.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. help displaying info from structure
    By kisiellll in forum C Programming
    Replies: 6
    Last Post: 04-04-2009, 12:51 PM
  2. Question about getting an info class from another Form
    By Joelito in forum C# Programming
    Replies: 0
    Last Post: 10-16-2006, 01:02 PM
  3. Help doing an e-mail program in c...
    By Tyler_Durden in forum C Programming
    Replies: 88
    Last Post: 01-02-2005, 03:12 PM
  4. Binary trees search problem...
    By Umoniel in forum C Programming
    Replies: 2
    Last Post: 02-22-2004, 02:29 PM
  5. Replies: 3
    Last Post: 12-06-2001, 05:30 AM