Tool for generating class properties in C#

Posted on 2007-07-26
Last Modified: 2010-07-27

Is there any equivalent of VB6 ClassBuilder in C#?
I need to generate a class with a few properties, their getter and setter methods.

Is there any in-built or free third party tool that does this?
Question by:rajesh_khater
    LVL 9

    Accepted Solution

    The 'Encapsulate Field' refactoring ability of the IDE will do most of what you need?

    Create a simple private field in your class - then right click - select Refactor->Encapsulate Field.. - this will generate the property with getter/setter methods for you.
    LVL 1

    Author Comment

    Ok. Can the IDE also generate a constructor that accepts parameters for each and every member variable of the class?
    LVL 9

    Expert Comment

    > Can the IDE also generate a constructor that accepts parameters for each and every

    no, I don't think so.  I am not sure this is something that you would often do by default...
    LVL 96

    Assisted Solution

    by:Bob Learned
    You can use the Class Diagram tool.  The right-most button in the Solution Explorer is the 'View Class Diagram' button.

    Here is the complete MSDN reference for Class Diagrams:

    Working with Class Diagrams


    Featured Post

    Better Security Awareness With Threat Intelligence

    See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

    Join & Write a Comment

    Article by: Najam
    Having new technologies does not mean they will completely replace old components.  Recently I had to create WCF that will be called by VB6 component.  Here I will describe what steps one should follow while doing so, please feel free to post any qu…
    This article introduced a TextBox that supports transparent background.   Introduction TextBox is the most widely used control component in GUI design. Most GUI controls do not support transparent background and more or less do not have the…
    It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
    This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    21 Experts available now in Live!

    Get 1:1 Help Now