/ Visual Studio 2012

Update to WebTools 2012.2 to resolve System.ComponentModel.Composition.ImportCardinalityMismatchException

Today one of my teams was greeted by a Visual Studio crash upon opening their solution. It happened with no changes to the solution over the weekend, but some Windows Updates were remotely installed to the machines.

After some testing we found that the crash will go away by ensuring that the latest version of the WebTools 2012.2 is installed. Since these machines are blocking all kinds of features of Internet Explorer (such as Javascript and exectutable downloads), getting the updated version installed was quite a hassle.

The direct link is here:

  1. Get the ASP.NET 2012.2 pieces then get one of these
  2. Web Tools 2012.2 for any regular Visual Studio 2012 or Web Tools 2012.2 for Visual Studio Web Express

Update the ASP.NET 2012.3 and Web Tools 2012.3 are now out as well:

(Thanks Scott)

Exception details:


Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.ComponentModel.Composition.ImportCardinalityMismatchException
Stack:
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(System.ComponentModel.Composition.Primitives.ImportDefinition, System.ComponentModel.Composition.Hosting.AtomicComposition)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExportsCore(System.Type, System.Type, System.String, System.ComponentModel.Composition.Primitives.ImportCardinality)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExportedValueCore[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.String, System.ComponentModel.Composition.Primitives.ImportCardinality)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExportedValue[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.String)
   at System.ComponentModel.Composition.Hosting.ExportProvider.GetExportedValue[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]()
   at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]()
   at Microsoft.VisualStudio.Progression.CommonIconHelper.Initialize(System.IServiceProvider)
   at Microsoft.VisualStudio.Progression.LanguageService.CSharp.IconHelper.Initialize(System.IServiceProvider)
   at Microsoft.VisualStudio.Progression.LanguageService.CSharp.CSLanSvcProvider.InitializeProvider()
   at Microsoft.VisualStudio.Progression.LanguageService.CSharp.CSLanSvcProvider.EnsureInitialized()
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
   at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
   at System.Windows.Threading.DispatcherOperation.InvokeImpl()
   at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
   at System.Windows.Threading.DispatcherOperation.Invoke()
   at System.Windows.Threading.Dispatcher.ProcessQueue()
   at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
   at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
   at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)

Jesse Houwing

Jesse Houwing

I love good coffee, meaning strong, dark espresso! Regular Expressions and LINQ are like word-puzzles! I am a trainer for Scrum.org, a member of the Microsoft ALM Rangers and awarded Microsoft MVP.

Read More
Update to WebTools 2012.2 to resolve System.ComponentModel.Composition.ImportCardinalityMismatchException
Share this