frankiie
frankiie

Reputation: 498

how to disable indent for close braces in Visual Studio C#

when I type {} in my code for examples it likes:

foreach(var item in items) {
            }

but I want

foreach(var item in items) {
}

Even I did options -> C# -> Code Style -> Formatting -> Indentation -> unclick indent open and close braces. So what's wrong with me?

Upvotes: 1

Views: 858

Answers (1)

Farshad Delavarpour
Farshad Delavarpour

Reputation: 205

Go to Tools -> Options -> Text Editor -> Basic -> Advanced -> Editor Help -> ensure "Pretty Listing (reformatting) of code" is enabled.

Upvotes: 1

Related Questions