Visual Studio Auto Open Properties

Here is my problem. I have a C # class file loaded in Visual Studio I'm working on. I created a class and created some properties inside the specified class. I destroyed the properties as follows:enter image description here

I destroy properties with a small +/ button -on each side. I want to collapse each of them, since I have many other classes with properties, and I do not want to see a lot of repeating code (get, set).

Closing them works fine, but after I work on some other classes in a single file, the properties open again so that I can see the code:

enter image description here

. , . / - ? ( Visual Studio 2010 # Express)

.

+5
3

, . CTRL-M, O, , .

+2

@DJKRAZE - - Resharper. Resharper, . , :

enter image description here

4 /, .

Resharper . ( ) , (Edit > Advanced > Format Document ):

enter image description here

0

You can use this:

#region some_name
//your variables or code whatever
#endregion

And then you can roll up a specific code, and it's good that it does not open, as it happens in your case.

See if it worked.

0
source

All Articles