-
June 2nd, 2009, 04:34 PM
#1
#pragma message not displaying
I am sure this a compiler setting I have over looked. But can anyone tell me why my pragma message is not showing up in the build window?
It has been years since I have tried to use this.
Basic code as follows:
Method ()
{
#pragma message ("Reminder here .....")
}
Init called the Method.
-
June 2nd, 2009, 05:32 PM
#2
Re: #pragma message not displaying
I'm not sure I understood, but pragma message will output text message while you are compiling your source not at run time, and your syntax does look OK.
-
June 2nd, 2009, 06:02 PM
#3
Re: #pragma message not displaying
From what I remember, "#pragma message ("some text") when compiling, it should display this message in the Build window. Is this correct?
-
June 2nd, 2009, 06:11 PM
#4
Re: #pragma message not displaying
Originally Posted by rkruis
From what I remember, "#pragma message ("some text") when compiling, it should display this message in the Build window. Is this correct?
Yes, as pointed out in my post.
"pragma message will output text message while you are compiling your source"
-
June 3rd, 2009, 12:03 PM
#5
Re: #pragma message not displaying
Thanks STLDude.
Any ideas what warning level should be set to, so this appears in my build window? I am sure it is a setting like that, that I have incorrect.
-
June 3rd, 2009, 12:09 PM
#6
Re: #pragma message not displaying
This pragma message works with all warnings levels 1 to 4, so you should see it in Output window in Visual Studio. http://www.dr-bill.net/CSC076/class_...26/pragmas.htm for some more info.
-
January 9th, 2013, 05:30 AM
#7
Re: #pragma message not displaying
This is an old thread, but the problem is new for me...
Just started using VS2012, and I'm having this same problem. The messages to not appear in the build window. Build errors appear, but not messages. I cannot find a switch in the options that might turn the display of these messages on.
-
January 10th, 2013, 03:17 AM
#8
Re: #pragma message not displaying
First, please further prefer opening a new thread instead of waking up a (very) old one!
Well, I see two possible causes:
- it is skipped by other preprocessor directives: #if, #ifdef, etc;
- the project uses precompiled headers and you have put #pragma message before including "stdafx.h"; note that, in this case all preprocessor directives are ignored.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|