locked
soap:ServerServer was unable to process request. 0x80040216 An unexpected error occurred. Platform RRS feed

  • Question

  • iam trying to cal fetch method of crm service and having this error plese help me out

    following is my code writen in onload

     

     

     

     

    //SETTING UP CRM SERVICE


    var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
    xmlhttp.open('POST', 'http://172.17.86.7/mscrmservices/2006/crmservice.asmx', false);

    xmlhttp.setRequestHeader('Content-Type', 'text/xml; charset=utf-8');
    xmlhttp.setRequestHeader('SOAPAction', '\"http://schemas.microsoft.com/crm/2006/WebServices/Fetch\"');

    //BUILDING THE FETCH XML TO BE SEND
    var FetchXML = "<?xml version=\"1.0\" encoding=\"utf-8\"?>"+"\n\n"+"<soap:Envelope"+
        ' xmlnsTongue Tiedoap="http://schemas.xmlsoap.org/soap/envelope/"'+
        ' xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"'+
        ' xmlns:xsd="'">http://www.w3.org/2001/XMLSchema">'+
        ' <soap:Body>' +
        ' <fetchXml xmlns="'">http://schemas.microsoft.com/crm/2006/WebServices">'+
    '&lt;fetch mapping=\'logical\' &gt;'+"\n"+
    '&lt;entity name=\'contact\' &gt;'+"\n"+
      '&lt;attribute name=\'lastname\'/ &gt;'+"\n"+
    '&lt;filter type=\'and\' &gt;'+"\n"+
    '&lt;condition attribute=\'firstname\'operator=\'eq\' value=\'anders\'/ &gt;'+"\n"+
    '&lt;/filter &gt;'+"\n"+
     '&lt;/entity &gt;'+"\n"+
     '&lt;/fetch &gt;'+"\n"+
    '</fetchXml>'+
    '</soap:Body>'+
    '</soap:Envelope>';
     alert(FetchXML);


    //SENDING QUERY
    xmlhttp.send(FetchXML);


    //GETTING THE RESULT OUT
    var xmlResponse = xmlhttp.responseXML;
    alert(xmlResponse.xml);
    alert(xmlResponse.text);

     


     

     

     

     

    alert('got up to here');

     

    Monday, May 26, 2008 4:57 AM

Answers