Search

Can't create Item Template for SSDT Data Projects with DependentUpon child items by David Gardiner

Active

1
0
Sign in
to vote
Type: Bug
ID: 777886
Opened: 1/30/2013 6:03:13 AM
Access Restriction: Public
0
Workaround(s)
0
User(s) can reproduce this bug
Most project types in Visual Studio support the ability to add items via custom templates.

It is possible to use a VSIX extension with a wizard to cause files to be added as 'children' nodes (cf. Web form .aspx pages and their code-behind .aspx.cs files)

Unfortunately this doesn't seem to work for Database Projects.
Details (expand)

Product Language

English

Version

SQL Server 2012 SP1

Category

Developer Tools (SSDT, BIDS, etc.)

Operating System

Windows 7 Professional (SP1)

Operating System Language

US English

Steps to Reproduce

1. Create a VSIX extension package in Visual Studio 2012
2. Add an Item Template project
3. Configure the item template project to add to .sql files
4. Add a C# class library with an implementation of the IWizard interface
5. In this class, call the ProjectItems.AddFromFile(filename) method to cause the filename to be added as a child of the parent item.

Actual Results

Items are all added to the project but without being made children of the parent node.

Expected Results

Child items should be added as children (using the DependentUpon element in the project file)

Platform

X64

Virtualization

 
File Attachments
File Name Submitted By Submitted On File Size  
MatrixGroup.DatabaseTemplates.zip (restricted) 1/30/2013 -
Sign in to post a comment.
Posted by Microsoft on 2/25/2013 at 8:47 AM
Thanks for your feedback. Unfortunately we're not planning on making any improvements to this feature in the near future.
Posted by David Gardiner on 1/30/2013 at 6:07 AM
I believe the problem is related to the OAProjectItem class return null as the implementation of the ProjectItems property.
Sign in to post a workaround.