Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2226
  • Last Modified:

IIS 6 need to run in x86 (32 bit mode) but on a Windows 2003 x64 server

Hi there,

Our development environment is a Windows 2003 x86 server but production is Windows 2003 x64 server. I've tested a webservice fine on the dev server now when I attempt to get to work on the live server I keep getting:

Could not load file or assembly 'xxxxxxxxxxx' or one of its dependencies. An attempt was made to load a program with an incorrect format

I think this is because my solution and all projects target x86, we need to specifically do rather than Any CPU due a Crystal Reports XI 2 dependency, the dlls don't work on x64. Anyway when I deploy to the x64 production server I get these errors.

http://support.microsoft.com/kb/894435/en-us
tells me how to switch but I'll have to do for all IIS websites I can't do selectively so am reluctant to yet. Is there any other was I can do this short of setting up another x64 server in vmware or something and testing?

Also http://support.microsoft.com/kb/894435/en-us tells me how to switch between modes but what is the actual command to run to tell what version is currently running?

Thanks
0
craigdev
Asked:
craigdev
2 Solutions
 
PugglewuggleCommented:
I believe that IIS runs as 32-bit (WOW) on Windows Server 2003 x64. I don't think it's IIS causing this problem.
However, ASP.NET runs separately and you need to configure it as required in either 32-bit or 64-bit mode.
You might check this out: 32-bit DLLs go in a different place in Windows x64 and require some special commands to register them. I'm not 100% sure of how this works but that is a start!
I hope this helps!
0
 
Anurag ThakurCommented:
I am assuming that you want to make your code compatible with x86 (32 bit) Platforms only and not with any other platforms

in that case you might need to do a rebuild of your solution and then publish your website

for doing so go to the configuration manager, there is a drop down for active solution platforms and in that select <new> a new window for new solution platform comes

in that form in the combobox Type or select the new platform select x86 and click ok
build in this configuration and test it
it should do a build for x86 platforms only
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now