I am writing a series of custom project wizards. The wizards will be as
small as an add project item (custom class) wizard and as large as adding 5
separate projects dynamically based on user selection to the solution,
creating references to other projects, etc.
I have spent some time looking at the options...
The current (2002) implementation was done using the C++ wizard
extensibility (a ton of default.js files and default.htm files) and is hardly
manageable.
To reduce code duplication and move to a more powerful language I would like
to move the wizards to a custom C# IDTWizard implementation.
Has anyone had enough experience with both to know how much "plumbing" i am
going to lose by moving away from the default wizard. It seems to me that
common.js and the default.js could be ported without too much hassle, at
which point i am working in C# instead of javascript and html.
Thanks,
Steve
Muahahaha, am already doing that :P Anywho, what I've done is created a class
which implements the IDTWizard interface. From there, I create the solution,
projects, and projectItems that I need to add. From that point, I actually
created several different base wizards (IE: MCIS_Module, MCIS_Class,
MCIS_AssemblyInfo) which contain the personalized wizard symbols that are
basically duplications of the files found here:
C:\Program Files\Microsoft Visual Studio .Net 2003\Vb7\VBWizards
Now, I am still dealing with the default.js and the template files. I don't
mind, the only problem I am having is in the default.js file....everytime I add a
new file programmatically using the AddFromTemplate method of the ProjectItems
collection object, the selProj variable is null :( But I got it working with a
code hack. It works, fine and dandy. But, what you'll want to look into is
creating new wizards (almost all examples are C++ or C#, I don't remember if I
even found 1 that was VB.Net). Look especially at the IDTWizard interface of the
EnvDTE namespace (EnvDTE.IDTWizard). The execute method is what you need to
start with :)
Have fun and good luck. Next time you want someone to send you some code, make
sure you give them your real email address :P
Mythran
> I am writing a series of custom project wizards. The wizards will be as
> small as an add project item (custom class) wizard and as large as adding 5
[quoted text clipped - 18 lines]
>
> Steve
Steve Baker - 29 Sep 2004 18:19 GMT
If I understand you correctly you are using these "base wizards" for
the add project item functionality. Are you doing this to avoid having
to recreate the wizard.RenderTemplate functionality?
Thanks,
steve
> Muahahaha, am already doing that :P Anywho, what I've done is created a class
>which implements the IDTWizard interface. From there, I create the solution,
[quoted text clipped - 42 lines]
>>
>> Steve