#pragma warning (C# Reference)
#pragma warning may be used to enable or disable certain warnings.
#pragma warning disable warning-list #pragma warning restore warning-list
Parameters
- warning-list
-
A comma-separted list of warning numbers. Enter the numbers alone, without the "CS" prefix.
When no warning numbers are specified, disable disables all warnings and restore enables all warnings.
warning list
http://msdn.microsoft.com/en-us/library/ms228296.aspx
use the number at the end (after the zeros) as the warning number
Edit by SJ at MSFT: Also, I added a note to this topic in VS 2010 steering you to the Output window to find the warning number.
Edit by SJ at MSFT: Also, I added a note to this topic in VS 2010 steering you to the Output window to find the warning number.
- 6/26/2009
- MattFenner
- 10/3/2011
- SJ_at_MSFT
Misspelling
"A comma-separted..." should read "A comma-separated..."
Edit by SJ at MSFT: This appears to have been corrected in VS2008. But please keep reporting if you see an error.
Edit by SJ at MSFT: This appears to have been corrected in VS2008. But please keep reporting if you see an error.
- 9/1/2011
- noonand2
- 10/3/2011
- SJ_at_MSFT