How to force an immediate writing of the printf() buffer content to console ???

Discussion in 'C++' started by Peter Smirnov, Aug 11, 2003.

  1. I wrote something with printf() to the console (under Windows) in a DLL.
    Then I called back a routine and detected that the output of the later called code
    was written PRIOR to the previous text to the console.
    So I am searching for a way to force Windows (Visual C++) to release the current content
    of the printf buffer.

    I read somewhere that appending a '\n' would do that. But: I already appended a '\n'
    and it didn't help.

    As far as I remember there is a function like flush() or so which has a similar meaning.

    Could someone help me ?

    Thank you
    Peter
    Peter Smirnov, Aug 11, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. TR
    Replies:
    0
    Views:
    551
  2. Dawn Minnis
    Replies:
    6
    Views:
    474
    Lawrence Kirby
    Feb 8, 2005
  3. Miktor
    Replies:
    7
    Views:
    11,996
    Joe Bacigalupa
    Aug 9, 2005
  4. Replies:
    5
    Views:
    3,410
    James Kanze
    Mar 4, 2008
  5. xingye
    Replies:
    9
    Views:
    260
    Michael Lu
    Apr 19, 2004
Loading...

Share This Page