我收到了"试图加载程序格式不正确"错误在SQL Server复制项目 [英] I get a "An attempt was made to load a program with an incorrect format" error on a SQL Server replication project
问题描述
确切的错误如下:
无法加载文件或程序集Microsoft.SqlServer.Replication,
版本= 9.0.242.0,文化=中性公钥= 89845dcd8080cc91
它依赖或1。一个试图加载程序与
格式不正确。
Could not load file or assembly 'Microsoft.SqlServer.Replication, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. An attempt was made to load a program with an incorrect format.
我最近开始后两个月移动到另一个项目再次在这个项目上的工作。它完美地工作之前,我已经双重检查所有的引用。
I've recently started working on this project again after a two month move to another project. It worked perfectly before, and I've double checked all the references.
推荐答案
我已经找到了解决办法。我最近升级我的机器到Windows 2008服务器64位。该SqlServer.Replication命名空间是为32位平台编写的。所有我需要做的就是它重新运行是设置目标平台在项目建设性质为X86。
I've found the solution. I've recently upgraded my machine to Windows 2008 Server 64-bit. The SqlServer.Replication namespace was written for 32-bit platforms. All I needed to do to get it running again was to set the Target Platform in the Project Build Properties to X86.
这篇关于我收到了"试图加载程序格式不正确"错误在SQL Server复制项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!