Silverlight中WCF在添加引用中不能发现的问题
来源:互联网 发布:js视频如何拉动进度条 编辑:程序博客网 时间:2024/06/05 09:00
Silverlight中WCF在添加引用中不能发现的问题
1.开始以为是项目添加到VSS中,文件只读导致的,把所有只读都检查了一遍后,发现问题依旧
2.上网查了一下,说是配置文件有问题,结果检查Web.config文件,发现文件内容如下
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="false" />
</behavior>
</serviceBehaviors>
</behaviors>
<bindings>
<customBinding> //这个customBinding其实是不需要的
<binding name="PAImport.Web.wcfMain.customBinding0">
<binaryMessageEncoding />
<httpTransport />
</binding>
</customBinding>
</bindings>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true"
multipleSiteBindingsEnabled="true" />
<services>
<service name="PAImport.Web.wcfMain">
<endpoint address="" binding="customBinding" bindingConfiguration="PAImport.Web.wcfMain.customBinding0"
contract="PAImport.Web.wcfMain" />
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
</service>
</services>
</system.serviceModel>
发现配置文件多了很多东西,结果找了一个项目,可以正常发现WCF的项目,看了一下web.config文件
发现,注意是<system.serviceModel>这一段,根本不需要那么多东西,直接用下面的内容替换掉,重新生成后,
WCF就能在项目中成功发现了
<system.serviceModel>
<behaviors>
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="false" />
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
</system.serviceModel>
- Silverlight中WCF在添加引用中不能发现的问题
- Silverlight中WCF定义的类,在客户端不能发现的问题
- Silverlight应用程序中添加WCF服务的问题(整理)
- Silverlight部署中WCF文件在IIS中不能浏览问题
- 解决有时候silverlight在VS2008中不能调试的问题
- 关于在Silverlight中添加图片的问题?
- Silverlight中引用wcf出现“给定关键字不在字典中”的错误
- 在wcf中,客户端在单独的类库中,如何引用
- Xamarin中wcf的引用
- Silverlight中WCF的动态部署
- 在阶段总结中发现的问题
- 解决在Silverlight中调用WCF控制台程序宿主时跨域问题
- silverlight 中datagrid不能选中行的问题
- Silverlight下的WCF服务之三:调用WCF服务从数据库中取出数据显示在datagrid中
- 如何用silverlight 做用于图片展示的画廊(三):利用silverlight + WCF +Linq 保存图片或照片,并利用silverlight +WCF下载图片显示在画廊中
- 在Silverlight窗体中添加可重用的背景
- win7+VS2010+WCF不能添加服务引用
- 5步教你在Silverlight中使用WCF服务
- Linux ALSA声卡驱动之五:移动设备中的ALSA(ASoC)
- the difference of QRectF&QRect
- mysql 更改数据库引擎
- Linux下常用文件解压(包括rpm、deb包)
- 拖放
- Silverlight中WCF在添加引用中不能发现的问题
- Initial RAM disk(initrd)
- Python运算符重载
- Xcode4单体测试结果覆盖率的确认方法
- mysql的limit的优化
- Qt下的几种透明效果
- 检查BST程序
- 容器的遍历(未完待续……)
- Silverlight中WCF的动态部署