Question

A solution containing my MVC application is having nearly 20 different projects (one of them is MVC, few are WCF service applications, and the rest are class libraries.

They all work, and gets build fine.. but the issue is they are giving warnings related to platforms while doing build. I have checked in the configuration manager that some of them are set as "x86" platform, and some of them are set for "Any CPU" and I feel I receive the warnings due to this.

As a developer, and in order to support cross-platform, I think I need to set all projects under this solution to target "AnyCPU".

I would like to know if this is the safer approach? or if there is any risk involved during deployment?

Any inputs over this, much appreciated.

Was it helpful?

Solution

AnyCPU is the least restrictive and should be fine. x86 will restrict to 32-bit process and require running in WOW64 mode on 64-bit platforms. x64 will limit it to 64-bit. AnyCPU creates DLLs that can run in the current loaded process (whether it is 32 or 64 bit). This should be the option unless you have some sort of limitation or optimization that requires you to target a specific platform.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top