Migrate an extension created with Managed Package Framework for Projects to Visual Studio 11

已答覆 Migrate an extension created with Managed Package Framework for Projects to Visual Studio 11

  • 2012年3月12日 上午 11:35
     
     

    Hello,

    I have a Visual Studio 2010 extension developed with Managed Package Framework for Projects, Visual Studio 2010. Until now, there is no version of MPF for Projects for Visual Studio 11. Has someone experience regarding this type of migration? There are changes that must be implemented in MPF for Projects or migration can be done without any change?

    Thanks.

    Mircea

所有回覆

  • 2012年3月12日 下午 04:37
     
     已答覆

    To get mine to install, I just modified my source.extension.vsixmanifest file by copying the VisualStudio element in the SupportedProducts element and set the Version attribute to "11.0".  That allowed it to install under VS 2010 and VS 2011.  Everything seems to work just fine.  However, there is one odd glitch that I haven't looked into yet.  At some random point either right when a project is opened or working with the project (adding files, etc.) the VS 2011 IDE seems to get stuck in a loop doing something and the title bar flashes between the standard title and a "Not responding" title.  At that point I need to click on the Close button on the title bar to get it unstuck.  It only seems to do it once and it's fine after that.  Since it's still a beta, I'm not sure if the problem is Visual Studio's or the extension's.

    Eric

    • 已提議為解答 EWoodruff 2012年3月12日 下午 04:37
    • 已標示為解答 Mircea11 2012年3月16日 上午 10:31
    •  
  • 2012年3月16日 上午 10:31
     
     

    Hello Eric,

    It also works for me with a small change. I have also updated the reference to Microsoft.VisualStudio.Shell.10.0 to 11.0.0.0 version. But I have encountered another problem. My extension works fine in Visual Studio 11 experimental instance. However, when I deploy the extension, it appears in Extension Manager but not in Visual Studio About Box and no project is added in New Project Dialog. In Visual Studio log file appears the message:

    <description>Error in Template (C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 11.0\COMMON7\IDE\EXTENSIONS\...XYZ_Project_Template.zip), file (XYZ_Project_Template.vstemplate).  Unregistered ProjectType (XYZProject).  This can be caused by an incorrect ProjectType or because the project type package is not installed.</description>

    Do you have any clue about what caused this? All .dlls and other extension files seems to be in place.

    Thanks,

    Mircea

  • 2012年3月16日 下午 02:03
     
     
    I also found that "devenv /setup" must be performed at the end of the install process in order to make Visual Studio 11 beta to scan for the new extensions.
  • 2012年3月16日 下午 03:03
     
     

    I didn't have to run "devenv /setup".  I didn't rebuild my extension under VS 2011 either.  I made the change to the VS2010 project and rebuilt it under VS 2010 with the modification to the VSIX manifest so that it installs under either version.  I could be your project system has dependencies that mine doesn't which may explain the differences.

    Eric