日期:2014-05-17  浏览次数:20848 次

wcf初学者问题
小弟初学wcf 有个问题想请教下各位大侠
我的wcf配置采用netNamedPipeBinding绑定方式 想要实现同一台电脑上的两个进程间通信
服务已经成功启动了..在客户端 中添加服务引用  引用地址我填的是net.pipe://localhost/stockquoteservice
但却找不到这个服务 报错为

元数据包含无法解析的引用:“net.pipe://localhost/stockquoteservice”。
读取管道时出错: 管道已结束。 (109, 0x6d)。
读取管道时出错: 管道已结束。 (109, 0x6d)。
如果该服务已在当前解决方案中定义,请尝试生成该解决方案,然后再次添加服务引用

请问哪里出问题了..
我的服务配置如下:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  

  <system.serviceModel>

    <services>

      <service behaviorConfiguration="" name="CaculateHost.CaculateService">

        <endpoint binding="netNamedPipeBinding" bindingConfiguration=""

            contract="CaculateHost.ICaculateService" />

        <host>

          <baseAddresses>

            <add baseAddress="net.pipe://localhost/stockquoteservice" />

          </baseAddresses>

        </host>

      </service>

    </services>

  </system.serviceModel>
</configuration>

------解决方案--------------------
关注,还没有用过wcf的netNamedPipeBinding。
我现在练习一下去