Is there a simple way to disable automatic formatting for a specific file in Visual Studio 2008 using ReSharper?
On the navigation options at the top select "Tools" and then select "Manage Extensions". I had CodeMaid, Visual Assist, and Rosalyn installed. Seems like an update start to cause these auto formatting issues. I disabled them and do this fixed it.
How do I turn off auto format in VS Code? Open VS Code editor and click the “Settings” icon. Search “Formatter” and select the formatter for which you want to disable auto format. Find the “Editor: Format On Save” option and uncheck the box next to it.
To access this options page, choose Tools > Options from the menu bar. In the Options dialog box, choose Text Editor > C# > Code Style > Formatting.
Configure code formatting rules in optionsSelect ReSharper | Options from the main menu or press Alt+R O . Use the Code Editing | General Formatting Style page to check and to configure the options that apply in all languages.
AFAIK, there is no option to conditionally disable the Auto-Format by file type or specific file with ReSharper 4.5. The only option is to enable/disable for all files:
ReSharper > Options > Editor: Auto-format on semicolon/closing brace
In ReSharper 7 (and few prior versions) you can specify generated files masks, those will not be formatted.
ReSharper->Options->Code Inspection->Generated Code->Generated file masks
For example if I have a file that contains reference data (as an array, for example), I call file for example States.data.cs and add *.data.cs to generated files masks list.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With