Microsoft Developer Network >
Forums Home
>
Microsoft Visual Studio 2010 Beta 2 Forums
>
Visual Studio Extensibility Beta 2
>
How to add a VsPackage using C++ to a new Isolated Shell
How to add a VsPackage using C++ to a new Isolated Shell
- Hi,
I created a new VS Isolated Shell project and got 4 projects. ShellExtensionsVSIX, VSShellStub2, VSShellStub2.AboutBoxPackage and VSShellStub2UI
When I added a VSPackage project using C#, all is fine. I added this one to the ShellExtensionsVSIX project using the AddContent button of the vsixmanifest designer.
When I do exactly the same using C++ for the package. The package is not loaded when the shell starts. And I got an exclamation mark at the reference of VSPackageCpp under the ShellExtensionsVSIX project.
Are any other steps necessary?
Thanks for help!
Answers
Here are steps to do this in Beta2. We are working on making it simpler for RTM.
After adding a new C++ package project to the solution, do the following.
(i) Open ShellExtensionsVSIX project properties and select the VSIX tab. In the text box that has the path to output location, add a "\" after the "...\Application".
(ii) Open the Source.Extension.vsixmanifest file in this project, open Add Content, select VSPackage and point it to newly added C++ package (If you kept the default names, it will called vspakage1).
(iii) Add a project to project reference from ShellExtensionsVSIX to UI project of the new added C++ package (it will called vspackage1UI).
(iv) Unload the ShellExtensionVSIX project (right click on the ShellExtensionsVSIX project, and click unload project).
(v) Open the unloaded project in the editor (right click and select edit project). Add the following element to the the Project to project reference for the UI project (Add it after <Name>VSPackage1UI</Name>).
<VSIXSubPath>1033</VSIXSubPath>
(vi) Reload and build.
--
Regards,
Saurabh
http://blogs.msdn.com/saurabhjain- Proposed As Answer bySaurabh Jain VSMSFT, OwnerWednesday, November 04, 2009 5:14 AM
- Edited bySaurabh Jain VSMSFT, OwnerWednesday, November 04, 2009 5:15 AMforgot the last step.
- Marked As Answer byHenry2323 Wednesday, November 04, 2009 10:28 AM
All Replies
Here are steps to do this in Beta2. We are working on making it simpler for RTM.
After adding a new C++ package project to the solution, do the following.
(i) Open ShellExtensionsVSIX project properties and select the VSIX tab. In the text box that has the path to output location, add a "\" after the "...\Application".
(ii) Open the Source.Extension.vsixmanifest file in this project, open Add Content, select VSPackage and point it to newly added C++ package (If you kept the default names, it will called vspakage1).
(iii) Add a project to project reference from ShellExtensionsVSIX to UI project of the new added C++ package (it will called vspackage1UI).
(iv) Unload the ShellExtensionVSIX project (right click on the ShellExtensionsVSIX project, and click unload project).
(v) Open the unloaded project in the editor (right click and select edit project). Add the following element to the the Project to project reference for the UI project (Add it after <Name>VSPackage1UI</Name>).
<VSIXSubPath>1033</VSIXSubPath>
(vi) Reload and build.
--
Regards,
Saurabh
http://blogs.msdn.com/saurabhjain- Proposed As Answer bySaurabh Jain VSMSFT, OwnerWednesday, November 04, 2009 5:14 AM
- Edited bySaurabh Jain VSMSFT, OwnerWednesday, November 04, 2009 5:15 AMforgot the last step.
- Marked As Answer byHenry2323 Wednesday, November 04, 2009 10:28 AM

