How to differentiate between various exception while calling a webservice in using .net?

Posted by nRk on Stack Overflow See other posts from Stack Overflow or by nRk
Published on 2010-06-02T08:23:02Z Indexed on 2010/06/02 8:53 UTC
Read the original article Hit count: 165

Filed under:
|
|

Hi,

I am consuming one webservice, while consuming there can different types expception might occur depeninding on various situation like.. network failur, invalid soap data or exception from serverside also might occur.

How can I differntiate between these different excpetion?

Because in my application, with these exceptions I need to update the various status Like: if network failure occurs Status will be "unable to connect webservice" so I can try after sometime later. If exception comes from Web server , no need to call/try again.

Thanks
nRk

© Stack Overflow or respective owner

Related posts about ASP.NET

Related posts about web-services