SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am running Visual studio 2010 on OS 64 bit and one of my web service application that sharepoint code throwing an error.

Exception Details: System.BadImageFormatException: Could not load file or assembly 'Microsoft.Office.Server.Search, Version=, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. An attempt was made to load a program with an incorrect format.

How to resolve this?

share|improve this question
up vote 1 down vote accepted

What is the platform selected in your project's properties Build section? It should be Any CPU.

share|improve this answer
I did that. still the same. Will SharePoint 2007 64 + Os 64 + Vs2010 will support? – James123 Jan 28 '12 at 2:29

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.