• tsorg banks
  • 0 Points
  • Member since 2007

  • Chatter
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
  • 0

I'm currently trying to send a soap message to logon to my salesforce application. I send the following message:

<?xml version="1.0" encoding="utf-16"?>
<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">
    <login xmlns="urn:enterprise.soap.sforce.com">
      <username />
      <password />

I get the following reply:

<?xml version="1.0" encoding="utf-16"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
      <faultstring>Content is not allowed in prolog.</faultstring>

I'm using a webservice test tool called webstudio (downloaded from gotdotnet). It allows me to invoke the 'login' webservice via a .net proxy called which works fines, but when I use it to invoke the 'login' method via http soap request it fails as above.

Please can anyone explain why salesforce is returning this error. Can anyone send me a complete soap request that will allow me to call the 'login' method, as I'm guessing salesforce doesn't like something in the soap I'm sending it.

Thanks very much in advance for any help.