/quiet

 

Updated: July 20, 2015

For the latest documentation on Visual Studio 2017 RC, see Visual Studio 2017 RC Documentation.

Prevents the compiler from displaying code for syntax-related errors and warnings.

/quiet  

By default, /quiet is not in effect. When the compiler reports a syntax-related error or warning, it also outputs the line from source code. For applications that parse compiler output, it may be more convenient for the compiler to output only the text of the diagnostic.

In the following example, Module1 outputs an error that includes source code when compiled without /quiet.

Module Module1  
    Sub Main()  
        x()  
    End Sub  
End Module  

Output:

E:\test\t2.vb(3) : error BC30451: Name 'x' is not declared.

x

~

Compiled with /quiet, the compiler outputs only the following:

E:\test\t2.vb(3) : error BC30451: Name 'x' is not declared.

System_CAPS_ICON_note.jpg Note

The /quiet option is not available from within the Visual Studio development environment; it is available only when compiling from the command line.

The following code compiles T2.vb and does not display code for syntax-related compiler diagnostics:

vbc /quiet t2.vb  

Visual Basic Command-Line Compiler
Sample Compilation Command Lines

Show: