CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2003
    Posts
    16

    List *.mp3 files for a given directory

    Hi all,

    I've been searching the web all night for an example of how to find all *.mp3 files in a directory on Linux. I can list the directories contents, but I need to limit the results to *.mp3 only.

    Appreciate any help or direction that you can provide. Using plain old C on Linux.

    Thanks,
    -Jim

  2. #2
    Join Date
    Dec 2008
    Posts
    4

    Re: List *.mp3 files for a given directory

    I guess that your file names are char arrays, so you could compare the four last characters of the file name and see if it is ".mp3".

  3. #3
    Join Date
    Feb 2005
    Location
    Madrid (Spain)
    Posts
    511

    Re: List *.mp3 files for a given directory

    Reading about this I found this:

    http://msdn.microsoft.com/en-us/libr...73(VS.85).aspx

    but how can I get buffer of the console without W32 API (C++ or pure C).

    There are one moment when buffer is represented in the console: Can we hooking it ?


    Regards !!

  4. #4
    Join Date
    Dec 2008
    Posts
    4

    Re: List *.mp3 files for a given directory

    Quote Originally Posted by juanpast View Post
    Reading about this I found this:

    http://msdn.microsoft.com/en-us/libr...73(VS.85).aspx

    but how can I get buffer of the console without W32 API (C++ or pure C).

    There are one moment when buffer is represented in the console: Can we hooking it ?


    Regards !!
    The c++ standard console is cout, it is a buffer. I think you could find something with this.
    But, are you sure this is the right place to talk about this?
    Last edited by Wek21; December 10th, 2008 at 05:56 PM. Reason: Add something

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured