Visual Studio Developer Center > Visual Studio Forums > Visual Studio Class Designer > Help with class creation Namespace and output directory from Class Designer
Ask a questionAsk a question
 

QuestionHelp with class creation Namespace and output directory from Class Designer

  • Tuesday, September 15, 2009 1:43 AMTodd Nine Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Forgive me if this is obvious, but I can't find any documentation on how to do this.  I'm working on upgrading our billing system, so I'm creating a class diagram that represents the relationship between all our Plans.  I want my classed to be generated with the namespace "Common.Model.Plan" and have the .cs file output into the directory ${projectdir}\Model\Plan.  However, I can't seem to find this setting in my class diagram properties as changing the custom namespace value in my diagrams properties it still produces a file with just the "Common" namespace in the base of my project, not it the namespace sub directory.

    Thanks,
    Todd

All Replies

  • Thursday, October 22, 2009 8:10 AMYang CaoMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Hi, Todd,

    Sorry that customizing the namespace and file location is not an option right now. This is a limitation and it makes Class Designer a less handy tool to design large project.

    Regards,
    Yang

  • Wednesday, November 25, 2009 10:55 AMDaRamirezSoto Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    A good workaround for this could be:

    1) Create a class in the appropriate folder with the option Add new Item.
    2) Drop the class in to the class designer.

    This way you can still add the properties and functions the same way you would normally do.

    Hope this Helps