ASP.NET MVC3 runtime error while trying to load a 64-bit C ++ / CLI assembly

Update: The question is updated after finding out what causes ASP.NET/Razor errors.

I have an ASP.NET MVC3 project that references a C ++ / CLI project that is configured to compile as x64 because it must run on Windows Azure (there is no AnyCPU setting for C ++ / CLI).

The problem is that as soon as I configure the parameters of the C ++ / CLI project platform on x64 (in Build-> Configuration Manager), build a solution, then open a random view that I get a warning about ASP.NET trying to load the wrong assembly format followed by a bunch of errors caused by Razor syntax errors.

Screenshot from some random preview:
enter image description here

Screenshot of the log: VS2010 Error List

:

: ASP.NET: "LZGEncoder" . .

, , ++/CLI , , ( IntelliSense " Razor).

reset ++/CLI Win32, , , , , - MVC3.

​​ASP.NET - ? ( Azure), , VS2010. .

Update:
#, C, P/Invoke, , ++/CLI, , .

, MVC3/Razor VS2010, .

+5
4

, , , dll ++/CLI x64. ASP.NET , Win32 AnyCPU, .

2 ++/CLI - Win32 x64, , x64, Azure, , Win32 Azure .

, , - #, C P/Invoke, # "AnyCPU", .

, /dll , Razor, , AnyCPU Win32, x64.

! , ASP.NET MVC3 afterall.

+2

, ++- , .

  • ? MVC 3 MVC 4, ?
  • , , - .dll. , Visual Studio.

, ++- - MVC ? # DLL?

0

, , ASP.NET/Windows Azure. , Visual Studio. Visual Studio, ASP.NET MVC Windows Azure, , .

,

Ming Xu.

0
source

I had the same problem with a specific project, but I do not have DLLs compiled as x64. What I did to solve the problem was to clean the project, and that seems to do the trick. The only thing I can think of has changed on my system since the problem started is my installation of Visual Studio 2012 RC.

-1
source

All Articles