How to disable warnings in Visual Studio for a Visual Basic Web Deployment Project

前端 未结 3 1474
独厮守ぢ
独厮守ぢ 2021-01-01 01:34

For our VB.NET websites we use SVN for Source Control and CruiseControl.NET for continuous integration.

To use the SVN build number in the compilation by CruiseCont

3条回答
  •  抹茶落季
    2021-01-01 02:00

    Had a very similar situation with an old VB web project, and we did not want to add the #pragma blocks all over the code calls. For some reason, adding the lines to the fields did not make Visual Studio builds ignore/suppress the warnings.

    However, I found a different approach. By adding this in the .vbproj file after the area ignored the obsolete warnings in VS 2017: 612;618

    Common MSBuild project properties Description of configuration setting:

    DisabledWarnings Suppresses the specified warnings. Only the numeric part of the warning identifier must be specified. Multiple warnings are separated by semicolons. This parameter corresponds to the /nowarn switch of the vbc.exe compiler.

提交回复
热议问题