Is there a ToString() generator available in Visual Studio 2010?

前端 未结 11 839
伪装坚强ぢ
伪装坚强ぢ 2021-01-03 17:39

Is there any way to generate a ToString() using Visual Studio 2010?

I really don\'t want to do this by hand!

[EDIT]

I\'m looking for a s

11条回答
  •  感动是毒
    2021-01-03 18:14

    If you don't write your own ToString method, Object provides one for you (although not very useful, since it only return the namespace and name of the objects type).

    Otherwise, you have to create it yourself, since the IDE cannot possibly know what you want to output as an object's ToString method.

提交回复
热议问题