Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to Complete XML for SOAP Client
    primarykey
    data
    text
    <p>I am trying to implement a SOAP client to handle electronic reporting of California payroll taxes for the web service described by the WSDL file at this location: <a href="https://fsettestversion.edd.ca.gov/fsetproxy/fsetservice.asmx" rel="nofollow">FSET Service</a>. In this WSDL file, there are references to several schemas including one at <a href="http://schemas.xmlsoap.org/ws/2004/08/addressing" rel="nofollow">http://schemas.xmlsoap.org/ws/2004/08/addressing</a> that seems to be stopping my program before it even gets to the OnBeforeExecute event.</p> <p>To get off the ground with this project, I am trying to access the <strong>Ping</strong> function declared in the WSDL file.</p> <p>I am just now getting some experience with SOAP client creation in Delphi. I am using Delphi 2010. Here is what I did to get to this point. I used the WSDL importer to import the file at the above address. It created a unit called fsetservice for me. Then, I added a form to my project, to which I added an HTTPRIO component. I set the component's WSDLLocation to a local copy of the WSDL file, put a couple of TMemos on the form to capture the request and response headers and added code to do that. Then I set up a button and in its OnClick event, I wrote this code:</p> <pre><code>procedure TForm1.Button1Click(Sender: TObject); var sResponse: String; begin sResponse := GetFsetServiceSoap.Ping; end; </code></pre> <p>When I click the button, I get this message before my breakpoint in the HTTPRIO OnBeforeExecute event is reached: </p> <blockquote> <p>Header <a href="http://schemas.xmlsoap.org/ws/2004/08/addressing:Action" rel="nofollow">http://schemas.xmlsoap.org/ws/2004/08/addressing:Action</a> for ultimate recipient is required but not present in the message</p> </blockquote> <p>I know we should only ask one question per posting, but sometimes you don't know enough to ask just one good question:</p> <p><em>EDIT: To save time for anyone else with the same questions, I am putting the answers I have found under these questions.</em></p> <p>It looks like the HTTPRIO component may be checking the XML imported from the WSDL file for completeness against the schemas referenced in the WSDL. That would seem pretty cool but is it true? </p> <p>*ANSWER: Not true, at least according to the note at the bottom of the page at <a href="http://www.tutorialspoint.com/wsdl/wsdl_definition.htm" rel="nofollow">http://www.tutorialspoint.com/wsdl/wsdl_definition.htm</a>. According to the note, it is not necessary for the schema to actually exist at that location, it just has to uniquely identify the schema used in the WSDL.* </p> <p>In the automatically created (and unmodified) GetFsetService function, I can step all the way to the end and the error happens on return with no seemingly no possibility to step into the actual process where the error gets invoked. Is there a way to do it that I am missing?</p> <p><em>ANSWER: I am still not sure on this but it seems that the answer is no. Anyway, although it will be more tedious to write this from scratch, that is a better solution than waiting for a miracle from the WSDL wizard.</em> </p> <p>Did I miss something that says I need to implement the FsetService interface that was automatically created for me?</p> <p><em>ANSWER: Apparently not.</em></p> <p>I saw in Marco Cantu's book Mastering Delphi 2005 that there is an application supplied by Borland (WebAppDbg.exe)that allows you to look at the HTTP you send on a particular port. I tried it but got no result. Would this be helpful and if so, what port should I use? </p> <p><em>ANSWER: Use the Fiddler2 tool. Nice find.</em></p> <p>How do I get past this error?</p> <p><em>ANSWER: Do it by hand.</em> </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload