Supress/Disable/Solve Visual Studio Build Warning

落花浮王杯 提交于 2019-11-30 19:32:38
Jeremy Thompson

Suppressing MSBuild warnings is still not possible.

Warnings with MSB prefix are thrown by MSBuild. Currently, we can't suppress MSBuild warnings.

Ref: https://social.msdn.microsoft.com/Forums/vstudio/en-US/96b3ea2e-92ed-4483-bbfe-a4dda3231eb9/suppress-msb4126?forum=tfsbuild

There are a few you can suppress in the PropertyGroup of your .csproj file, for example:

<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>None</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>

However none exist for the incorrectly specified as a file warning.


Since you cant fix the root cause of the MSB3178 due to the file extension of a 3rd party DLL, you have justification to ignore that particular warning.

Related SO threads here and here and on MSDN. The exact same question on MSDN.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!