How to get rid of Naming rule violation messages in Visual Studio?

后端 未结 9 624
我在风中等你
我在风中等你 2020-12-14 05:10

I just installed Visual Studio 2017. When I open an existing website, I get all sorts of warning messages such as this one:

IDE1006 Naming rule violat

9条回答
  •  误落风尘
    2020-12-14 06:03

    What this rule asserts is that fields must be private.

    You can convert it to a Property by adding the {get;set;} after the field.

    This removed the error for me.

提交回复
热议问题