ReSharper: Namespace does not correspond to file location

Root namespace is needed to be changed as following.

enter image description here


Check to make sure your assembly name matches your new namespace. If you've changed your folder structure to match your new namespace, you may still see the ReSharper alert until you update the project properties.


I also had this problem with a folder/namespace and none of the above steps fixed it.

In my case I had to do this in Visual Studio:

  • Right-click the "problem" folder in the solution explorer to open the properties
  • Ensure the "Namespace Provider" is set to true

This fixed the ReSharper issue for me and I was able to adjust namespaces as normal.


As delliottg's comment says, in Visual Studio, go to

Project > [project name] Properties > Application

and change "Assembly name" as well as "Default namespace".