Partilhar via


Nesting Projects

Enterprise application developers who use your VS Package can conveniently group similar types of projects together in Visual Studio by using project nesting. For example, the Enterprise Template project uses nested projects to group projects into categories. Business facade projects, Web UI projects, and so on are grouped together in one category.

In this scenario, there is no limit to the number of projects the developer can nest under each parent project, although the developer can programmatically provide limits. This type of grouping can also be made recursive, in which case the projects of the same type as a child project can be nested under the child to become a subproject of the child, which is a subproject of the parent. For more information, see Introduction to Visual Studio Templates.

Project nesting is not an intrinsic part of Visual Studio. You have to write the code to enable nesting and subproject nesting within child projects. The parent project is a special VSPackage, or project type, created and registered with its own GUID that includes the code that is required to implement project nesting.

You can find an example of nested projects in the C# Example.Nested Project sample.

Nested projects example

Nested projects example

Nested Projects Solution

See Also

Concepts

How to: Implement Nested Projects

Considerations for Unloading and Reloading Nested Projects

Wizard Support for Nested Projects

Registering Project and Item Templates

Implementing Command Handling for Nested Projects

Filtering the AddItem Dialog Box for Nested Projects

Checklist: Creating New Project Types

Context Parameters

Wizard (.Vsz) File