If you are using 10.0 or 10.1:http://help.arcgis.com/en/sdk/10.0/arcobjects_net/componenthelp/index.html#//00460000002w000000
If your web service is x64 then you have to bind and license to ArcGIS Server. Desktop is strictly 32 bit, i.e. x86.
I suspect that you have not configured your web service to run as x86, i.e. 32 bits only.
Thanks! Besides the settings in C# project and IIS, I also need to change license initialization codes as follows:ESRI.ArcGIS.RuntimeManager.Bind(ESRI.ArcGIS.ProductCode.EngineOrDesktop);IAoInitialize m_AOInit = new AoInitializeClass();esriLicenseStatus licenseStatus = m_AOInit.Initialize(esriLicenseProductCode.esriLicenseProductCodeArcServer);Then the whole thing begins to work!
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.