带有WP7的WCF,帮助! [英] WCF with WP7, help !

查看:81
本文介绍了带有WP7的WCF,帮助!的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个产品列表以及其他信息,我想通过WCF将该列表发送到WP7,它的感觉如何?非常感谢

I have a list of products together with other information, I want to send that list via WCF to WP7, how do it like? thanks so much

推荐答案

使用List<products>作为服务方法类型的返回参数.

并将产品创建为DataContract.

例如:
use List<products> as a service method type return parameter.

And create Products as DataContract.

Eg:
public List<products>  GetAllProducts()
{
          do some thing
}


on client side(WPF)
ServiceClient client=new ServiceClient()
 List<products> =client.GetAllProducts()</products></products></products>


这篇关于带有WP7的WCF,帮助!的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆