bug in menu for printing text file

This is a discussion on bug in menu for printing text file within the C++ Programming forums, part of the General Programming Boards category; What does my print function, only print after you choose to close the program? Also, how can I make my ...

  1. #1
    Unleashed
    Join Date
    Sep 2001
    Posts
    1,765

    bug in menu for printing text file

    What does my print function, only print after you choose to close the program?
    Also, how can I make my print function valid C++ if it's not already?

    The source is attached.

    *prays this umpteenth try at a post works*
    [EDIT]
    WOOHOO! It worked.
    [/EDIT]
    Attached Files Attached Files
    The world is waiting. I must leave you now.

  2. #2
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231
    >>What does my print function, only print after you choose to close the program?
    Possibly because you never fclose() the stream.

    >>how can I make my print function valid C++ if it's not already?
    read up on C++ io streams. There are plenty of guides about, here's one (I'm not saying this is a good one, just an example). Here's another reference.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

  3. #3
    Unleashed
    Join Date
    Sep 2001
    Posts
    1,765
    > Possibly because you never fclose() the stream.
    DOH!

    > Here's another reference.
    Thank you Hammer for your help.
    I'll have a look.
    The world is waiting. I must leave you now.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Basic text file encoder
    By Abda92 in forum C Programming
    Replies: 15
    Last Post: 05-22-2007, 02:19 PM
  2. Dikumud
    By maxorator in forum C++ Programming
    Replies: 1
    Last Post: 10-01-2005, 07:39 AM
  3. Unknown Memory Leak in Init() Function
    By CodeHacker in forum Windows Programming
    Replies: 3
    Last Post: 07-09-2004, 10:54 AM
  4. what does this mean to you?
    By pkananen in forum C++ Programming
    Replies: 8
    Last Post: 02-04-2002, 03:58 PM

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