How do I fix the indentation of selected lines in Visual Studio

Selecting all the text you wish to format and pressing CtrlKCtrlF shortcut applies the indenting and space formatting.

As specified in the Formatting pane (of the language being used) in the Text Editor section of the Options dialog.

See VS Shortcuts for more.

Leave a Comment