Ajuda - Busca - Membros - Calendário
Versão Completa: Web service + encoding
Fórum Script Brasil > Programação & Desenvolvimento > Delphi, Kylix
Bryant
Galera,

Estou com uma dúvida enorme, criei um webservice, sem NADA, dai setei o encoding dele para http://schemas.xmlsoap.org/soap/encoding/

Depois tentei alterar para vários valores: vazio, "aaaa" e por aí vai.. mas ele sempre inclui.

Código abrindo o WSDL pelo IE

CODE
<?xml version="1.0" encoding="utf-8" ?>
- <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="ICoBioWebServiceIntfservice" targetNamespace="http://tempuri.org/" xmlns:tns="http://tempuri.org/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/">
  <portType name="ICoBioWebServiceIntf" />
- <binding name="ICoBioWebServiceIntfbinding" type="tns:ICoBioWebServiceIntf">
  <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" />
  </binding>
- <service name="ICoBioWebServiceIntfservice">
- <port name="ICoBioWebServiceIntfPort" binding="tns:ICoBioWebServiceIntfbinding">
  <soap:address location="http://localhost/testews/FingerprintBioWS.dll/soap/ICoBioWebServiceIntf" />
  </port>
  </service>
  </definitions>



Código abrindo o SOAP pelo IE
CODE
<?xml version="1.0" ?>
- <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
- <SOAP-ENV:Body>
- <SOAP-ENV:Fault>
  <faultactor />
  <faultcode>SOAP-ENV:Server</faultcode>
  <faultstring>O documento XML deve ter um elemento de nível superior. Line: 0</faultstring>
  </SOAP-ENV:Fault>
  </SOAP-ENV:Body>
  </SOAP-ENV:Envelope>


Esse erro eu obtenho quando utilizo esse encoding, mas se eu removo ele aparece de qualquer forma, meu web.config não tem nada, por isso nem é setado por lá.

Alguém tem idéia?
Bryant
Ninguém resolveu isso para o Delphi 7 até hoje?

CODE
O documento XML deve ter um elemento de nível superior. Line: 0


Muito estranho isso...
Esta é uma versão simplificada de nosso conteúdo principal. Para ver a versão completa com maiores informações, formatação e imagens, por favor clique aqui.
Invision Power Board © 2001-2012 Invision Power Services, Inc.