CStdioFile - Reading last line...

This is a discussion on CStdioFile - Reading last line... within the Windows Programming forums, part of the Platform Specific Boards category; How can I use CStdioFile to read the last line of a file. I thought I could use a while ...

  1. #1
    Registered User xlnk's Avatar
    Join Date
    Mar 2002
    Posts
    186

    Question CStdioFile - Reading last line...

    How can I use CStdioFile to read the last line of a file. I thought I could use a while loop and just keep reading each line till the end, but it did not seem to work. Are there any other alternatives or methods to do this? Thank you.


    [edit] I got it!
    Last edited by xlnk; 02-28-2004 at 09:39 AM.
    the best things in life are simple.

  2. #2
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348
    Check out CFile. For simple file I/O, you could implement C++ ifstream via binary mode.

    Kuphryn

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Reading a file line by line
    By Raskalnikov in forum C Programming
    Replies: 8
    Last Post: 03-18-2009, 11:44 PM
  2. Replies: 1
    Last Post: 05-20-2006, 11:17 PM
  3. Replies: 6
    Last Post: 04-28-2006, 12:06 PM
  4. file reading line by line
    By Jerry & Tom in forum C++ Programming
    Replies: 1
    Last Post: 01-17-2003, 01:47 PM
  5. Greenhand want help!
    By leereg in forum C Programming
    Replies: 6
    Last Post: 01-29-2002, 05:04 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21