"Cleanup Code" menu item is disabled and Cleanup Code option page is empty
The solution:
1) Open ReSharper | Extension Manager;
2) Find installed “ReSharper.StyleCop” plugin;
3) Remove it;
4) Install "StyleCop by JetBrains" plugin instead.
We unfortunately have two different versions of Stylecop plugins in the extension manager. The "ReSharper.StyleCop" version is causing issues.
The "StyleCop by JetBrains" version is maintained by us. We'd love to merge the two, but author of the original is currently not responding to any form of contact.
Please sign in to leave a comment.
Ok that seems to be installed now... how to I use it to get a text export of all the methods used in the projects?
Thanks.
In my case, the problem is actually that files like RouteConfig.cs are considered "installed by a NuGet package" and they get excluded from Code Cleanup. I have no idea how to re-enable that functionality.
It happened to me with UnityConfig.cs (inserted by the unity.mvc nuget package). If I rename it, I can run code cleanup. If I rename it back, the option is greyed again. However, I can find no suspicious mention of it in the nuget package, the targets files, the dotsettings files, or anywhere else.
The solution doesn't apply to me and I have the same symptoms.
Cleanup Code; Silent Cleanup Code; Reformat Code; and Apply Code Style from the Resharper=>Edit menu are grayed out and I can't access them.
My questions are:
I just have the Style Cop not the ReSharper.StyleCop plugin in my list along with a few others such as: Exceptional for ReSharper; Cyclomatic Complexity; Serialization Insprections; Enhanced ToolTip; etc. and I've used these for years.
Update: I have removed all plug-ins and I'm just running ReSharper and there isn't any change, the above menu items are all grayed out.
The Problem still exists in September 2018
Cleanup code menu is disabled, even though I have definitions
I have this issue and I don't have any StyleCop plugins installed. Is there any other known cause?
The problem still exists, but rebuilding the project usually helps.