如何使用Visual Studio编译具有64位dll引用的网站项目? [英] How to use Visual Studio to compile a website project having a 64 Bit dll reference?

查看:62
本文介绍了如何使用Visual Studio编译具有64位dll引用的网站项目?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

I have a website project in my .NET 4.0 solution. It has a reference to a 64 Bit dll. I am able to build / compile it from the command prompt. However, the build from Visual Studio fails with a bad image format exception, since Visual Studio by default uses the 32 Bit version of the compiler when compiling a website.

I tried setting the Toolpath property of the ASPNETCompiler task in the solution file, but Visual Studio does not seem to pick that up.

Is there a way to configure Visual Studio to use 64 Bit Compiler while compiling a website?

推荐答案

是的。在项目属性中,有一个平台设置,可以设置为32位,64位或任意。您应该可以将其设置为强制进行64位编译。



如何:将项目配置为目标平台 [ ^ ]
Yes. In your project properties there is a platform setting which can be set to 32bit, 64bit or Any. You should be able to set this to force 64bit compilation.

How to: Configure Projects to Target Platforms[^]


这篇关于如何使用Visual Studio编译具有64位dll引用的网站项目?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆