Reputation: 233
I am looking for a c# formatting which will do(like in Eclipse):
f(){
}
instead of
f()
{
}
I have checked tools->options formatting but could not find it.
Upvotes: 3
Views: 88
Reputation: 23208
Tools -> Options
-> Text Editor
-> C#
-> Formatting
-> New Lines
-> New line options for braces
-> Place open brace on new line for ....
There are a few options in there, I'm guessing you're likely wanting to disable most of those. But specifically in this case I believe is for Place open brace on new line for control blocks
.
In addition, check out the other options for C# in and around there. It's pretty extensive and most likely you'll be able to achieve whatever combination of style you desire.
Upvotes: 3
Reputation: 2731
Just follow this: Option -> Text Editor -> C# -> Formatting -> New Lines
Uncheck all the "New lines option for braces"
Upvotes: 3
Reputation: 9190
Tools > Options > Text Editor > C# > Formatting > New Lines > Place open brace on new line for control blocks.
Upvotes: 2