Click here to Skip to main content
15,896,290 members
Articles / Programming Languages / C#

A Better Way for a Client to Work with WCF Services

Rate me:
Please Sign up or sign in to vote.
5.00/5 (2 votes)
8 Nov 2010CPOL3 min read 49.2K   903   36  
A component which allows to work with WCF services in a robust way
/*
 * This source can be freely used, however it would be nice to hear when it 
 * is useful to someone. I can be contacted via my profile (JP van Mackelenbergh) 
 * on Codeproject.
 * 
 * First published Nov 2010, JP van Mackelenbergh
 * 
*/

using System;
using System.Runtime.Serialization;

namespace DynamicClientProxy
{
    /// <summary>
    /// This exception is thrown by the client proxy when problems occurred 
    /// with calls made to the service. This can for example be caused because 
    /// the service is no longer available or when an internal exception occurred 
    /// within the service.
    /// </summary>
    [Serializable]
    public class ConnectionProblemException : Exception
    {
        protected ConnectionProblemException(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }

        public ConnectionProblemException(string message, Exception innerException)
            : base(message, innerException)
        {
        }
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Architect Altran
Netherlands Netherlands
I am a relaxed guy, born in '73, who likes to develop software professionally in both my work and in my spare time.

Keywords are C#, WCF, WPF.

Comments and Discussions