首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >System.BadImageFormatException in VS2010 XAML设计器

System.BadImageFormatException in VS2010 XAML设计器
EN

Stack Overflow用户
提问于 2012-02-03 07:51:05
回答 1查看 1.1K关注 0票数 3

我使用"sqlite-netFx40-setup-bundle-x64-2010-1.0.79.0.exe") 1.0.79 (在我的项目中通过SQLite设置64位)。将SQLite绑定到GAC上。但是在XAML-Designer抛出中,请跟随异常:

代码语言:javascript
复制
    System.BadImageFormatException
    Die Datei oder Assembly "System.Data.SQLite, Version=1.0.79.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139" oder eine Abhängigkeit davon wurde nicht gefunden. Es wurde versucht, eine Datei mit einem falschen Format zu laden.
       bei System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
       bei System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
       bei System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection, Boolean suppressSecurityChecks)
       bei System.Reflection.Assembly.Load(AssemblyName assemblyRef)
       bei MS.Internal.Package.VSIsolationProviderService.RemoteReferenceProxy.VsReflectionResolver.GetRuntimeAssembly(Assembly reflectionAssembly)
       bei Microsoft.Windows.Design.Metadata.ReflectionMetadataContext.CachingReflectionResolver.GetRuntimeAssembly(Assembly reflectionAssembly)
       bei Microsoft.Windows.Design.Metadata.ReflectionMetadataContext.Microsoft.Windows.Design.Metadata.IReflectionResolver.GetRuntimeAssembly(Assembly reflectionAssembly)
       bei MS.Internal.Metadata.ClrAssembly.GetRuntimeMetadata(Object reflectionMetadata)
       bei Microsoft.Windows.Design.Metadata.AttributeTableContainer.d__c.MoveNext()
       bei Microsoft.Windows.Design.Metadata.AttributeTableContainer.GetAttributes(Assembly assembly, Type attributeType, Func`2 reflectionMapper)
       bei MS.Internal.Metadata.ClrAssembly.GetAttributes(ITypeMetadata attributeType)
       bei MS.Internal.Design.Metadata.Xaml.XamlAssembly.get_XmlNamespaceCompatibilityMappings()
       bei Microsoft.Windows.Design.Metadata.Xaml.XamlExtensionImplementations.GetXmlNamespaceCompatibilityMappings(IAssemblyMetadata sourceAssembly)
       bei Microsoft.Windows.Design.Metadata.Xaml.XamlExtensions.GetXmlNamespaceCompatibilityMappings(IAssemblyMetadata source)
       bei MS.Internal.Design.Metadata.ReflectionProjectNode.BuildSubsumption()
       bei MS.Internal.Design.Metadata.ReflectionProjectNode.SubsumingNamespace(Identifier identifier)
       bei MS.Internal.Design.Markup.XmlElement.BuildScope(PrefixScope parentScope, IParseContext context)
       bei MS.Internal.Design.Markup.XmlElement.ConvertToXaml(XamlElement parent, PrefixScope parentScope, IParseContext context, IMarkupSourceProvider provider, Boolean visitCodeModel)
       bei MS.Internal.Design.DocumentModel.DocumentTrees.Markup.XamlSourceDocument.FullParse(Boolean convertToXamlWithErrors)
       bei MS.Internal.Design.DocumentModel.DocumentTrees.Markup.XamlSourceDocument.get_RootItem()
       bei Microsoft.Windows.Design.DocumentModel.Trees.ModifiableDocumentTree.get_ModifiableRootItem()
       bei Microsoft.Windows.Design.DocumentModel.MarkupDocumentManagerBase.get_LoadState()
       bei MS.Internal.Host.PersistenceSubsystem.Load()
       bei MS.Internal.Host.Designer.Load()
       bei MS.Internal.Designer.VSDesigner.Load()
       bei MS.Internal.Designer.VSIsolatedDesigner.VSIsolatedView.Load()
       bei MS.Internal.Designer.VSIsolatedDesigner.VSIsolatedDesignerFactory.Load(IsolatedView view)
       bei MS.Internal.Host.Isolation.IsolatedDesigner.BootstrapProxy.LoadDesigner(IsolatedDesignerFactory factory, IsolatedView view)
       bei MS.Internal.Host.Isolation.IsolatedDesigner.BootstrapProxy.LoadDesigner(IsolatedDesignerFactory factory, IsolatedView view)
       bei MS.Internal.Host.Isolation.IsolatedDesigner.Load()
       bei MS.Internal.Designer.DesignerPane.LoadDesignerView(Boolean isReload)

此异常发生在所有Xaml-文件上。但是程序运行时没有错误。

..。编辑..。我编辑过,因为我甚至不被允许回复

发现并解决了问题..。

我只安装了64位SQLite,但是VS2010是一个32位进程。

安装32位SQLite也解决了这个问题

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2012-04-26 17:57:49

您只安装了64位SQLite,但是VS2010是一个32位进程。

安装32位SQLite也可以解决这个问题。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/9125350

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档