New files on Visual Studio are marked as Miscellaneous

Viewed 222

I added simple class file to the project and it marked as Miscellaneous.

enter image description here

Usually the following actions helped me in this case:
- Unload and Reload a projects
- Close solution, delete .vs file and reload solution

But it didn't help me now.
I used Build Loging tool to see what's wrong and I found the next error:

enter image description here

1 Answers

The problem was in .csproj file for problem solution.

<Import Project="..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.2.0.1\build\net46\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.props" Condition="Exists('..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.2.0.1\build\net46\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.props')" />  

I removed it and was loaded successfully.

Related