can any function, for example printf, restart from beginning of the same line? So we will not have multiple lines of output
Another question, any way to retrieve the previous ouput that have been bumped out of the window in case of large amount of output? I am using Windows VC.
Thanks!
lehe 0 Light Poster
Recommended Answers
Jump to Postprintf("\r");
It may be compiler-specific, it may be platform dependent, so use discretion but give it a try.
Jump to PostThe printf("\r") works really well to have the console screen overwrite the 'current' line. It will however just be another character in the output if cout is redirected to a file.
I used to use that feature to show progress for an old command line compiler, it would output …
All 5 Replies
MosaicFuneral 812 Nearly a Posting Virtuoso
ArkM 1,090 Postaholic
death_oclock 103 Posting Whiz
Murtan 317 Practically a Master Poster
ajay.krish123 -4 Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.