AlainD
AlainD

Reputation: 6607

Setting for formatting C-style comments for C#

Writing C# in Visual Studio 2019. With the following construct:

/* My comment
*/

Set the cursor to the right of comment and press Enter. This gets converted to:

/* My comment
 *
*/

I'd prefer:

/* My comment

*/

After hunting around in Tools > Options, could not find the setting for this...where is it?

Upvotes: 2

Views: 175

Answers (1)

DavidG
DavidG

Reputation: 118957

Open Visual Studio options and navigate to:

Text EditorC#Advanced

and uncheck Insert * at the start of new lines when writing / / comments

enter image description here

Upvotes: 5

Related Questions