次の方法で共有


download and video for the WCF/WPF/P2P chat application

Last week I posted a description of how to write a peer-to-peer chat application using WCF, with a WPF GUI layer isolated from the application logic, all built using .NET 4.0 and Visual Studio 2010.

The basic approach was adapted from the article at https://msdn.microsoft.com/en-us/library/cc297274.aspx
where Amit Bahree and Chris Peiris did something similar, using winforms for the GUI.

 

I’ve now posted the complete source code as a .zip file here.
Just unzip, open the solution file in Visual Studio 2010, and hit F5.

 

Also, here’s a video to walk you through the whole development process.

Comments

  • Anonymous
    May 02, 2010
    Hi! Thanks for the great sample app. When I want to start the application, I get the following error message: Cannot load the X.509 certificate identity specified in the configuration. Can you help me? Thanks Jus

  • Anonymous
    May 24, 2010
    Jus, In this example, the "App.config" file created by the WCF Service Configuration Editor tool will contain the following lines in the client endpoint definition: <identity>  <certificateReference storeName="My" storeLocation="LocalMachine"                        x509FindType="FindBySubjectDistinguishedName" /> </identity> If this isn't working, the quickest fix is to avoid using anything related to X.509 certificates. The application should actually function just fine if you remove the entire set of text from <identity> through </identity> (removing those tags as well). You can also diagnose problems with your local X.509 certificate by running the example code found at the bottom of: msdn.microsoft.com/.../system.security.cryptography.x509certificates.x509findtype.aspx

  • Anonymous
    April 20, 2011
    Hi, Thank you for great sample, but I am looking for a way to communicate 2 particular clients directly, in other words to create private chat... is there any way with netp2p binding? thanks a lot

  • Anonymous
    September 11, 2011
    InnerException {"Could not find endpoint element with name 'ChatEndpoint' and contract 'ChatBackend.IChatBackend' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this name could be found in the client element."}

  • Anonymous
    March 26, 2014
    Can you be gracious enough to send me the source code? I'll be highly obliged. The Link you provided is not working. Thanks

  • Anonymous
    November 25, 2015
    Can you please send me the code  as the link you provide is no more working. My Email Id-ramakant.verma24@gmail.com It will be really helpful for me