Note that there are some explanatory texts on larger screens.

plurals
  1. POCannot successfully run svcutil on net.tcp example in wcf examples
    text
    copied!<p>I just downloaded and ran the net.tcp binding example from the Microsoft WCF samples: WF_WCF_Samples\WCF\Basic\Binding\Net\Tcp\Default\CS</p> <p>I opened the solution and rebuilt it, launched the server from the server/bin directory, launched the client from the client/bin directory and everything worked fine.</p> <p>I added a new function to service.cs and then called it from client.cs. But visual studio gave this error: 'Microsoft.Samples.NetTcp.CalculatorClient' does not contain a definition for 'AddAndDouble' and no extension method 'AddAndDouble' accepting a first argument of type 'Microsoft.Samples.NetTcp.CalculatorClient' could be found (are you missing a using directive or an assembly reference?)</p> <p>I'm assuming it's giving this error because my generatedClient.cs file is now out of date, so I'm trying to run svcutil to generate a new generatedClient.cs file.</p> <p>But when I run svc util, this is what it says:</p> <hr> <p>c:\Program Files\Microsoft Visual Studio 9.0\VC>svcutil.exe net.tcp://localhost: 9000/servicemodelsamples/service/</p> <p>Microsoft (R) Service Model Metadata Tool [Microsoft (R) Windows (R) Communication Foundation, Version 3.0.4506.648] Copyright (c) Microsoft Corporation. All rights reserved.</p> <p>Attempting to download metadata from 'net.tcp://localhost:9000/servicemodelsampl es/service/' using WS-Metadata Exchange. This URL does not support DISCO. Microsoft (R) Service Model Metadata Tool [Microsoft (R) Windows (R) Communication Foundation, Version 3.0.4506.648] Copyright (c) Microsoft Corporation. All rights reserved.</p> <p>Error: Cannot obtain Metadata from net.tcp://localhost:9000/servicemodelsamples/ service/</p> <p>If this is a Windows (R) Communication Foundation service to which you have acce ss, please check that you have enabled metadata publishing at the specified addr ess. For help enabling metadata publishing, please refer to the MSDN documentat ion at <a href="http://go.microsoft.com/fwlink/?LinkId=65455" rel="nofollow">http://go.microsoft.com/fwlink/?LinkId=65455</a>.</p> <p>WS-Metadata Exchange Error URI: net.tcp://localhost:9000/servicemodelsamples/service/</p> <pre><code>Metadata contains a reference that cannot be resolved: 'net.tcp://localhost: </code></pre> <p>9000/servicemodelsamples/service/'.</p> <pre><code>The socket connection was aborted. This could be caused by an error processi </code></pre> <p>ng your message or a receive timeout being exceeded by the remote host, or an un derlying network resource issue. Local socket timeout was '00:04:59.9687500'.</p> <pre><code>An existing connection was forcibly closed by the remote host </code></pre> <p>If you would like more help, type "svcutil /?"</p> <p>So, I checked that the server was listening by doing this: netstat /an | find /i "9000" TCP 0.0.0.0:9000 0.0.0.0:0 LISTENING</p> <p>Any ideas what I'm doing wrong?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload