How to properly embed a custom wizard assembly in VSIX template project in VS 2013?
Asked Answered
R

1

6

I'm building a multi project template in Visual Studio 2013 consisting of a couple of item templates, a main project and a unit test project. I created a custom template wizard w/ a simple non-UI implementation of IWizard I needed to help me w/ references in my unit test project. It all works on my PC, but I'm struggling to get the VSIX to properly deploy that custom wizard assembly on other PCs. The extension itself installs okay, but upon creating my new project it blows up telling me it can't find my custom template wizard assembly.

I can tell from fusion log viewer its looking in various subfolders (PrivateAssemblies, PublicAssemblies, CommonExtensions) of the C:\Program Files (x86)\Visual Studio 12.0\Common7\IDE folder. I need to get that DLL to get into one of those folders. I see stuff on here about ProvideBindingPath attribute, but I've not had any luck so far.

I've tried quite a few of the suggestions here on SO, but most if not all of them are referencing VS2010 (which is different in this regard).

Any help is appreciated!

Revealment answered 10/3, 2014 at 16:26 Comment(0)
R
6

I've found a solution. Inside the VSIX manifest designer's Assets section, where you add your custom template wizard assembly, there is a box at the bottom that says "Embed in this folder:". If you enter the value ProjectTemplates in there, it will work.

What is actually happening when the VSIX extension is installed is that it's extracting the assembly (DLL) out to the /Common7/IDE/Extensions/{random letters denoting unzipped extension}/ProjectTemplates folder. Apparently this structure is what is expected.

I really hope this helps someone. It seems this process has changed since VS 2010 and the newer VS 2012/2013 documentation is a bit weak.

Screenshot attached.

Screen capture of VSIX manifest asset editor

Revealment answered 10/3, 2014 at 19:54 Comment(1)
For those who end up here after me, this did not solve the issue on VS2015.3.Moniquemonism

© 2022 - 2024 — McMap. All rights reserved.