C# – Force C# app to compile as x64 instead of AnyCpu

64-bitc

I've being driven up the wall trying to reference native x64 dlls in a C# app, using C# 2010 Express. I have a demo project that was converted from a 2008 project that has configuration and platform options in its properties, but the new projects that I've created don't! The dropdowns just don't exist – in fact I can't even switch from Debug to Release. Both of them use .Net Framework 4 and everything else seems the same between them.

In C++ and the converted C# project it's simple, you just open the solution's Configuration Manager and go, but my new C# project doesn't have that in the context menu.

I need to be able to reference the x64 dlls under x64 and the x86 dlls under x86, due to massive memory requirements. Can anyone explain why the option is missing or point me to how to fix it?

Best Answer

Select Build - Configuration Manager. Under the Platform select new, then select x64 there.