wsdl.exe not creating class for fault element

N

Nick Locke

I have already seen this:

and I assume that this is still correct. I had been hoping to see a
generated class definition relating to the fault element already definined
in the WSDL - but apparently not!

I will be returning effectively an array of Error Codes and Error
Descriptions. What is the recommended way to make sure that my (contract
first) WSDL correctly represents what I am going to return from ASP.NET? Or
is plan B to not actually formally define the error format in the WSDL?

Thanks, Nick.
 
J

John Saunders

Nick Locke said:
I have already seen this:


and I assume that this is still correct. I had been hoping to see a
generated class definition relating to the fault element already definined
in the WSDL - but apparently not!

I will be returning effectively an array of Error Codes and Error
Descriptions. What is the recommended way to make sure that my (contract
first) WSDL correctly represents what I am going to return from ASP.NET?
Or is plan B to not actually formally define the error format in the WSDL?

What I did is to define my fault messages in a separate schema, which is
referenced in the wsdl. I then ran that schema through XSD.EXE to get me
class definitions I could use in my code. When I wanted to generate a
SoapException corresponding to those faults, I serialized the generated
class into the Detail property of the SoapException.

John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,812
Latest member
GracielaWa

Latest Threads

Top