2

I want to suppress FXCOP error(CA1811) for specific vb.net function.
Like <SuppressMessage()> in c#, do we alternative of this in VB.net?

I am new to vb.net.

James Z
  • 12,209
  • 10
  • 24
  • 44

1 Answers1

0

FXCop analyzes the compiled assemblies, i.e., it doesn't care whether the assembly was written in C# or VB.NET.

Thus, the same technique that works in C# should also work in VB.NET. Note that, in VB.NET, the syntax for adding attributes is [SuppressMessage(...)] rather than C#'s <SuppressMessage(...)>.

Heinzi
  • 167,459
  • 57
  • 363
  • 519