'Call a Web Service' - The remote server returned an error: (400) Bad Request

May 27, 2010 at 5:35 PM
Edited May 27, 2010 at 11:09 PM

'Call a Web Service' question. Using a Sharepoint Dev server to call a web service on a remote server. Are there any examples out there to setup the Action?

I run a workflow and get the following error: "The remote server returned an error: (400) Bad Request"

It seems that I cannot add a Lookup Item. If I do that causes the error.

<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <InsertInc xmlns="http://server.com/webservices/">
      <EmailAddress>yo.me@blank.com</EmailAddress>
      <IncDesc>[%Project:Description%]</IncDesc>
      <SubjectID>PROJECT</SubjectID>
      <GroupName>APPDEV_HOL</GroupName>
      <LastNameAssigned>doran</LastNameAssigned>
    </InsertInc>
  </soap12:Body>
</soap12:Envelope>

How to get <IncDesc>[%Project:Description%]</IncDesc> to become text above. I created 2 workflows. One to run on the entry and one to run after it is saved. 

UPDATE: I found the issue is when a rich text box is used. I don't know how to get around this. Maybe a calculated column equal to the other column.

Coordinator
May 31, 2010 at 11:50 AM

The remote server returned an error: (400) Bad Request.

This means the request will be submitted but the web service reject it. Maybe an issue with the SOAP. Monitor the successfull SharePoint designer webservice call with Fiddler an check with it against your SOAP Envelope.

Bye, Christian

May 31, 2010 at 2:32 PM

Thanks for the response. I used another column for a description, but will see if Fiddler can give me a clue.