473,386 Members | 1,785 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Console::Writeline()

Hi

I've got an MFC application in VS2005(VC++). It's a mixed-mode application.
Whenever I use Console::Writeline() It never displays any thing (I don't get
any output).

Here is some code example:

void RbfProp::SetRbfProp(RbfPropDlg *rbfDlg)
{
actvFunc = gcnew String(rbfDlg->m_actvFunc);
itr = static_cast <int>(rbfDlg->m_itr);
Console::WriteLine("Activation function = String^",actvFunc);
}

cheers.

Manj.
Jan 4 '08 #1
2 1342
"Manjree Garg" <ga**@newsgroup.nospamwrote in message
news:FD**********************************@microsof t.com...
Hi

I've got an MFC application in VS2005(VC++). It's a mixed-mode
application.

Is this a console application?

Mark

--
Mark Salsbery
Microsoft MVP - Visual C++
Whenever I use Console::Writeline() It never displays any thing (I don't
get
any output).

Here is some code example:

void RbfProp::SetRbfProp(RbfPropDlg *rbfDlg)
{
actvFunc = gcnew String(rbfDlg->m_actvFunc);
itr = static_cast <int>(rbfDlg->m_itr);
Console::WriteLine("Activation function = String^",actvFunc);
}

cheers.

Manj.

Jan 4 '08 #2
Hi Manj,

I suspect you are calling Console::Writeline() in a GUI MFC application.
Win32 GUI system will not spawn any console window for Console::Writeline,
so you can not see any console window appear. This is expected and by
design. If I remember correct, the output text will go to "Output" window
in VS IDE(press Ctrl+W, O).

If you really wanted to spawn a new console window in GUI application for
debugging output, you may call AllocConsole win32 API to create one. The
article below demonstrates this approach:
http://www.codeproject.com/KB/cpp/ConsoleAdapter.aspx

Hope it helps.

Best regards,
Jeffrey Tan
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Jan 7 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: jabailo | last post by:
This is driving me crazy. I finally got the Remoting sample chat application working almost. When I run the chat client in VS.NET it goes into an endless loop -- that's because I assume that...
7
by: shawnk | last post by:
Hello Everyone How do you format format numbers right-justified using Console.WriteLine(), i.e I need to line up numbers in vertical columns and the MSDN documentation is pretty poor Here is the...
3
by: Roy Gourgi | last post by:
Hi, How would I set the width of lnSize to 6 in the statement Console.WriteLine("Size of {0} ", lnSize); Furthermore is there a way to combine these 3 statements into 1 ...
5
by: portroe | last post by:
Hi I am using console.Writeline in my simple program. I do not however see anything happening in the output window when I debug, there are also no error messages, Has anybody a tip on what...
4
by: Bob | last post by:
I just recently noticed that when I start my applicatoin in debug mode, the IDE hangs (no disk or CPU activity) indefinitely (at least 20 minutes). Pausing the application shows that it's hung up...
4
by: Leszek | last post by:
Can someone help me? Im trying to use console.writeline with ciag1. Application must read string, split it by "," and show every section between ",". Dim serwery_split() Dim elementy As...
3
by: Andrew Ducker | last post by:
We were using Console.Writeline from within our app, to do some routine debugging. And then we started having random problems when the code was run by a tester, on their own machine. We...
2
by: djc | last post by:
out of all the overloads that pop up via intellisense for console.writeline() the following one confuses me: Console.WriteLine (string format, params object arg) 1) whats the deal with...
3
by: Tracey | last post by:
How I can have the cursor remain at the end of the 2nd Console.WriteLine - (without a <carriage-return>/<line-feed>) Console.WriteLine("Hello World") Console.WriteLine("Press <enterto continue: ")...
1
by: =?Utf-8?B?RXJpayBFY2toYXJkdA==?= | last post by:
I am trying to create a class or function which does one extra thing then performs a normal Console.WriteLine, preferrably with all the overloads available and intact. Where I currently have: ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.