Need help

This is a discussion on Need help within the C Programming forums, part of the General Programming Boards category; My code has stored data enter into program into a text file.. I need a function that can make u ...

  1. #1
    Registered User
    Join Date
    Jan 2011
    Posts
    14

    Need help

    My code has stored data enter into program into a text file..
    I need a function that can make u view text files in program itself..
    Any1?..

  2. #2
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Ok, put on your thinking cap...

    You wrote a program that writes stuff to a disk file.

    Why can't you reverse that process and write one to read it?
    What steps did you complete to write the file?

  3. #3
    Infant of C
    Join Date
    May 2010
    Location
    Karachi, Pakistan
    Posts
    118
    you mean you have stored data in for example "mydata.txt" and you want to call a function that opens your mydata.txt in note pad it self?

  4. #4
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by C_programmer.C View Post
    you mean you have stored data in for example "mydata.txt" and you want to call a function that opens your mydata.txt in note pad it self?
    That's not what he said... he wants a file viewing function inside his own program...
    It should be plenty simple... open file... read line from file... display line on monitor... loop until done... close file.

  5. #5
    Infant of C
    Join Date
    May 2010
    Location
    Karachi, Pakistan
    Posts
    118
    Oh I see!

Popular pages Recent additions subscribe to a feed

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