Hi. I am not sure if its wx related.
I am trying to use printf("myfar %i",myvar); in a sample wx project but nothing appears in output window, any hints
PS: cout<< does not work either
Thanks
printf not working in wx
printf not working in wx
Who doubts nothing, Knows nothing
This is not a wx question, printf calls don't go through wx, just to your system
make asure you run from terminal and have a way to see the program's output
AND: try adding a line breask (\n) at the end of printf. or using flush. Or use std::cout << "something" << std::endl; often nothing will display until one line is complete or flushed

AND: try adding a line breask (\n) at the end of printf. or using flush. Or use std::cout << "something" << std::endl; often nothing will display until one line is complete or flushed
Qasim doesn't mention platform, but on windows you can't just printf or cout to the console. You have to add some wxWidgets so it is a console app and the console will connect to stdin, stdout and stderr. Unfortunatly, off the top of my head I don't remember what. If Qasim is building for win32 I'll look for the code.Auria wrote:This is not a wx question, printf calls don't go through wx, just to your systemmake asure you run from terminal and have a way to see the program's output
I suspect the problem might be though that Qasim isn't running from a console as Auria suggests.
Qasim, what is the output window a console that you ran the application from or a wxWindow/wxFrame that the application creates? Also, what platform are you building for.Qasim wrote: am trying to use printf("myfar %i",myvar); in a sample wx project but nothing appears in output window
-Max
If you are targeting windows these links might help
http://www.halcyon.com/~ast/dload/guicon.htm
http://forums.wxwidgets.org/viewtopic.p ... ut+windows
-Max
http://www.halcyon.com/~ast/dload/guicon.htm
http://forums.wxwidgets.org/viewtopic.p ... ut+windows
-Max