开发者

Can I automatically insert all members of a object somehow in Visual Studio?

I like to insert all members of a object automatically, so I dont need to type th开发者_Python百科em (or even click them). Ctrl + J gives me the dropdown, but I like them all in code with a default value:

MyObject.Member1=0;
MyObject.Member2="";
MyObject.Member3=0;

Any Add-In or existing shortcut that can help me with that?

Edit: I like to have the above generated automatically, so that I just need to put each default value there by myself.


I think the answer is there's no such thing available at the moment. ReSharper team suggested me to write a feature wish to them.


You can create a constructor or another method that preforms a setter on multiple fields for you.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜