faultcontract

WCF: Same Faultcontract on many methods

Take for example a project with 10 services and 20 methods on each service. All services inherit from a base services which has a security check. The first thing each method does is to make a call to the security check. This throws a security exception if there is a problem. Question is: Do I need to specify a FaultContract on each met...

svcutil fails against service with a fault contract

We have a WCF self hosted service which we have been developing for awhile. As part of our standard we have defined a FaultContract which we apply to operations. Recently we needed to add a new ServiceContract so we did that and added a simple method (void/no params) to it. Once we added this contract though SVCUtil would no longer ge...

WCF autogenerate FaultContracts

We have many WCF services, we have not been using contract first. So now we have a lot of code that throws exceptions, that are not specified in the FaultContracts. Other than manually inspecting the code. Is there a way to generate FaultContracts or at least get a warning when a FaultContract is missing? Thanks Shiraz ...

WCF : FaultContract(typeof(ExceptionDetail)) issue

I have put the attribute [FaultContract(typeof(ExceptionDetail))] for my operation contract. When I am trying to add the service th' a client app, I get this error - "Custom tool error: Failed to generate code for the service reference 'ServiceReference1'. Please check other error and warning messages for details." But when I comment o...

FaultException<T>() exception thrown by the service is not caught by the client catch(FaultException<T>)

Ok, I know I am missing something here. I have the following operation contract: public double DivideByZero(int x, int y) { if (y == 0) { throw new FaultException<ArgumentException> (new ArgumentException("Just some dummy exception") ,new FaultReason("some very bogus reason"), new...