Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / August 2007

Tip: Looking for answers? Try searching our database.

Adding SOAP:Fault elements within my WSDL.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Manpreet Sushil - 23 Aug 2007 04:26 GMT
I am having a Webservice within which i am throwing SOAP Exceptions and
therefore whenever something wrong happens a SOAP fault comes up in the
response - see below:

<?xml version="1.0" encoding="utf-8"?><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"><soap:Body><soap:Fault><faultcode>soap:Client<
/faultcode><faultstring>Fault

occurred</faultstring><faultactor>http://203.111.104.215/webservices/selcomm/selcomm.asmx</faultactor><detail><fau
ltcode

xmlns="http://tempuri.org/">-102</faultcode><faultstring
xmlns="http://tempuri.org/">Database not
found</faultstring></detail></soap:Fault></soap:Body></soap:Envelope>

Now my Problem is that my WSDL does not define any SOAP Fault elements as it
is the one that is auto generated via the .NET Framework when we do ?WSDL.
How can i add the fault elements within my WSDL? where will the fault
elements come and how will they look like?
John Saunders [MVP] - 23 Aug 2007 18:29 GMT
>I am having a Webservice within which i am throwing SOAP Exceptions and
> therefore whenever something wrong happens a SOAP fault comes up in the
[quoted text clipped - 14 lines]
> How can i add the fault elements within my WSDL? where will the fault
> elements come and how will they look like?

.NET will not generate fault elements in your WSDL. You will either have to
create your own WSDL file or do without fault elements.

Your other choice would be to switch to WCF, which does allow you to define
faults and will add them to the WSDL.
Signature

John Saunders [MVP]

Manpreet Sushil - 24 Aug 2007 00:34 GMT
Hi John,

Thanks for your reply. I have no idea at all about WCF. Can ypu please point
me to some resources where i can learn how to add fault elements within my
customer WSDL. Your help will be much appreciated.

> >I am having a Webservice within which i am throwing SOAP Exceptions and
> > therefore whenever something wrong happens a SOAP fault comes up in the
[quoted text clipped - 20 lines]
> Your other choice would be to switch to WCF, which does allow you to define
> faults and will add them to the WSDL.
Manpreet Sushil - 29 Aug 2007 02:06 GMT
I have been able to resolve this by referring to the W3 Website. thanks for
your help anyway.

> Hi John,
>
[quoted text clipped - 26 lines]
> > Your other choice would be to switch to WCF, which does allow you to define
> > faults and will add them to the WSDL.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.