Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3198
  • Last Modified:

VS 2010 Won't Open Anything

Recently, my mac (OS X 10.7) and the VM open in Parallels at the time crashed.  Since then, my VS 2010 Ultimate installation on a 32 bit windows 7 VM seems to be corrupted.  VS 2010 will start fine but as soon as I try to open anything I get this error:

Visual Studio has encountered an exception.  This may be caused by an extension

The error box goes on to recommend running VS 2010 with the /log option, which I did, and found the following long winded error, which occurs about 20 times and seems to cause another 5 errors reported as failures to load packages:

System.BadImageFormatException: Could not load file or assembly 'Microsoft.VisualStudio.Text.UI.Wpf.dll' or one of its dependencies. An attempt was made to load a program with an incorrect format. File name: 'Microsoft.VisualStudio.Text.UI.Wpf.dll' ---> System.BadImageFormatException: Could not load file or assembly 'Microsoft.VisualStudio.Text.UI.Wpf.dll' or one of its dependencies. An attempt was made to load a program with an incorrect format. File name: 'Microsoft.VisualStudio.Text.UI.Wpf.dll' Server stack trace: at System.Reflection.AssemblyName.nGetFileInformation(String s) at System.Reflection.AssemblyName.GetAssemblyName(String assemblyFile) at System.ComponentModel.Composition.Caching.ReflectionResolver.ResolveAssembly(String assemblyName, String codeBase) at System.ComponentModel.Composition.Caching.AttributedModel.ReflectionCacheServices.ReadAssemblyCore(IDictionary`2 cache) at System.ComponentModel.Composition.Caching.AttributedModel.ReflectionCacheServices.Read[T](IDictionary`2 cache, Func`2 loader, String key, T defaultValue) at System.ComponentModel.Composition.Caching.AttributedModel.ReflectionCacheServices.ReadAssembly(IDictionary`2 cache, String key, Assembly defaultAssembly) at System.ComponentModel.Composition.Hosting.CachedAssemblyCatalog.get_Assembly() at System.ComponentModel.Composition.Hosting.CachedAssemblyCatalog.<.ctor>b__0() at System.ComponentModel.Composition.Caching.AttributedModel.ReflectionCacheServices.<>c__DisplayClass6.<GetLazyTypeForPart>b__5() at System.Lazy`1.CreateValue() Exception rethrown at [0]: at System.Lazy`1.get_Value() at System.ComponentModel.Composition.Caching.AttributedModel.ReflectionCacheServices.<>c__DisplayClass9.<GetAccessorsFromCache>b__8() at System.ComponentModel.Composition.ReflectionModel.LazyMemberInfo.GetAccessors() at System.ComponentModel.Composition.ReflectionModel.ReflectionExtensions.ToReflectionMember(LazyMemberInfo lazyMember) at System.ComponentModel.Composition.ReflectionModel.ReflectionComposablePart.GetExportingMember(ExportDefinition definition) at System.ComponentModel.Composition.ReflectionModel.ReflectionComposablePart.GetExportingMemberFromDefinition(ExportDefinition definition) at System.ComponentModel.Composition.ReflectionModel.ReflectionComposablePart.GetExportedValue(ExportDefinition definition) at System.ComponentModel.Composition.Hosting.CompositionServices.GetExportedValueFromComposedPart(ImportEngine engine, ComposablePart part, ExportDefinition definition) at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExportedValue(ComposablePart part, ExportDefinition export, Boolean isSharedPart) at System.ComponentModel.Composition.Hosting.CatalogExportProvider.CatalogExport.GetExportedValueCore() at System.ComponentModel.Composition.Primitives.Export.get_Value() at System.ComponentModel.Composition.ExportServices.GetExportedValueFromLazy[T](Export export) at System.ComponentModel.Composition.ExportServices.<>c__DisplayClassa`1.<CreateStronglyTypedExportOfT>b__7() at System.Lazy`1.CreateValue() at System.Lazy`1.LazyInitValue() at System.Lazy`1.get_Value() at Microsoft.VisualStudio.Text.Utilities.GuardedOperations.InstantiateExtension[TExtension](Object errorSource, Lazy`1 provider)

The package load error (that occurs a couple times,  following the above) is:

SetSite failed for package [Microsoft.VisualStudio.Editor.Implementation.EditorPackage, Microsoft.VisualStudio.Editor.Implementation, Version=, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a][

Has anyone seen this before?  Does anyone know how to fix this?  Is this answered somewhere else and I just haven't found it yet?

Nothing will open, not even a new project.  In fact, if I try to create a new project, I get an error box saying "object reference not set to an instance of an object"
1 Solution
Anurag ThakurTechnical ManagerCommented:
My suggestion will be try to re-install the VS 2010 as it looks like that the installation is corrupted now
Complete un-install and re-install
Looks like an extions is the problem

Go to %LocalAppData%\Microsoft\VisualStudio\10.0\Extensions and copy then to a safe location and the remove them from the folder %LocalAppData%\Microsoft\VisualStudio\10.0\Extensions

You can also try to make sure that the file Windows\System32\Microsoft.VisualStudio.Text.UI.Wpf.dll exists or perhaps copy it from another development computer.

hope it helps.
Kelvin McDanielSr. Developer/ConsultantCommented:
I suggest you try to repair before reinstalling.
libby9284Author Commented:
Thanks!  It's working again now, I'd forgotten about the repair utility and hadn't wanted to do a complete uninstall and reinstall unless absolutely necessary.

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now