bsmall
bsmall

Reputation: 185

In visual Studio, when formating automatically, how to reduce block spacing to minimum?

When doing formatting is there an options to control and reduce spaces in blocks ?
enter image description here

Upvotes: 0

Views: 76

Answers (1)

Jack J Jun- MSFT
Jack J Jun- MSFT

Reputation: 5986

You can try the following steps to reduce extra blank lines.

First, please use hot key Ctrl+H to open replace function box.

Second, please select the code you want to format.

Third, please choose Use regular expression and Selection.

enter image description here

Finally, please input (?<=\r\n)\r\n in the find box and click the Replace all.

enter image description here

Upvotes: 0

Related Questions