Inline variable declaration not compiling

后端 未结 3 1543
旧巷少年郎
旧巷少年郎 2020-12-14 13:52

I\'ve been getting a message in Visual Studio 2017, specifically, IDE0018 Variable declaration can be inlined.

So I try using an inline variable declara

3条回答
  •  渐次进展
    2020-12-14 14:47

    In case the above answer doesn't work for you, as it didn't work for me do the following:

    Open the csproj file and check if you have the following package referenced in the file after the upgrade, if yes, remove it.

    
    

    Next, check the "Project ToolsVersion". It has to be 15.0, it probably is 14.0 though so you have to change that.

    
    

    Then simply reload the SOLUTION and you're good to go. Be aware that if you select "Reload Project" it will give you an error and not load it.

提交回复
热议问题