简体   繁体   English

无法加载文件或程序集“SharpSvn”或其依赖项之一。 尝试加载格式不正确的程序

[英]Could not load file or assembly 'SharpSvn' or one of its dependencies. An attempt was made to load a program with an incorrect format

I just downloaded the 64bit version of the SharpSVN here's the link ! 我刚刚下载了这个SharpSVN的64位版本的链接

When I run my application, error message displayed. 当我运行我的应用程序时,显示错误消息。 I have searched the net on how to fix this issue but I'm failed. 我已经在网上搜索了如何解决这个问题,但我失败了。 I tried the following solution: 我尝试了以下解决方案:

  1. setting the Configuration Manager to x64 as suggested on this post 设置配置管理器到x64这个的建议
  2. setting the startup config on this response 在此响应上设置启动配置
  3. also tried downloading x86 and set the config manager to x86. 还尝试下载x86并将配置管理器设置为x86。
  4. tried this also, adding assembly link 尝试了这个,添加组装链接

I'm using Win7, 64bit,.net 4.0. 我使用的是Win7,64bit,.net 4.0。

Solve it. 解决这个问题。

  1. Change my platform to x86 将我的平台更改为x86
  2. Output path to "bin\\" “bin”的输出路径
  3. Downloaded the x86 of SharpSVN (1.7008.2243.14245) 下载了SharpSVN的x86(1.7008.2243.14245)
  4. Add SharpSVN.dll in GAC. 在GAC中添加SharpSVN.dll。
  5. Delete the bin folder and rebuild solution 删除bin文件夹并重建解决方案

This is the link for the explanation. 这是解释的链接

If you're getting this error when trying to access a website hosted in IIS, you may need to adjust the "Enable 32-Bit Applications" setting in your application pool. 如果在尝试访问IIS中托管的网站时出现此错误,则可能需要调整应用程序池中的“启用32位应用程序”设置。 See this answer: https://stackoverflow.com/a/20525314/12484 请参阅此答案: https//stackoverflow.com/a/20525314/12484

This may also come down to a mismatched version of the Microsoft Visual C++ Redistributable Package depending on the version of SharpSvn and the version of Windows/Visual Studio. 这也可能归结为Microsoft Visual C ++ Redistributable Package的不匹配版本,具体取决于SharpSvn的版本和Windows / Visual Studio的版本。

Newer versions of SharpSvn have a dependency on the "Microsoft Visual C++ 2010 SP1 Redistributable Package". 较新版本的SharpSvn依赖于“Microsoft Visual C ++ 2010 SP1可再发行组件包”。

x64 - https://www.microsoft.com/en-us/download/details.aspx?id=13523 x64 - https://www.microsoft.com/en-us/download/details.aspx?id=13523

x86 - https://www.microsoft.com/en-us/download/details.aspx?id=8328 x86 - https://www.microsoft.com/en-us/download/details.aspx?id=8328

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 BadImageFormatException 无法加载文件或程序集或其依赖项之一。 试图加载格式不正确的程序 - BadImageFormatException Could not load file or assembly or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“ MWArray”或其依赖项之一。 试图加载格式错误的程序 - Could not load file or assembly 'MWArray' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“...”或其依赖项之一。 试图加载格式不正确的程序 - Could not load file or assembly '...' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“sapnco”或其依赖项之一。 试图加载格式不正确的程序 - Could not load file or assembly 'sapnco' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集xxx或其依赖项之一。 试图加载格式错误的程序。 - Could not load file or assembly xxx or one of its dependencies. An attempt was made to load a program with an incorrect format. 无法加载文件或程序集“xxx”或其依赖项之一。 试图加载格式不正确的程序 - Could not load file or assembly 'xxx' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“ MyLibrary”或其依赖项之一。 试图加载格式错误的程序 - Could not load file or assembly 'MyLibrary' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“JsonFx.Json”或其依赖项之一。 尝试加载格式不正确的程序 - Could not load file or assembly 'JsonFx.Json' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“ System.Data.SQLite”或其依赖项之一。 试图加载格式错误的程序 - Could not load file or assembly 'System.Data.SQLite' or one of its dependencies. An attempt was made to load a program with an incorrect format 无法加载文件或程序集“ Oracle.DataAccess”或其依赖项之一。 试图加载格式错误的程序。 缓存 - Could not load file or assembly 'Oracle.DataAccess' or one of its dependencies. An attempt was made to load a program with an incorrect format. Ncache
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM