I’m trying to call a web service in an Excel Macro:
Set objHTTP = New MSXML.XMLHTTPRequest objHTTP.Open 'post', 'https://www.server.com/EIDEServer/EIDEService.asmx' objHTTP.setRequestHeader 'Content-Type', 'text/xml' objHTTP.setRequestHeader 'SOAPAction', 'PutSchedule' objHTTP.send strXML
And I get back the following response:
<?xml version='1.0' encoding='utf-8'?> <soap:Envelope xmlns:soap='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> <soap:Fault> <faultcode>soap:Client</faultcode> <faultstring>Server did not recognize the value of HTTP Header SOAPAction: PutSchedule.</faultstring> <detail /> </soap:Fault> </soap:Body> </soap:Envelope>
Anybody out there done something like this before?
You SOAP action should also include namespace of the method e.g.
Find out what the namespace of your Service and add it in front of the method name PutSchedule.