System.data, ServiceModel.XmlSerializerFormatAttribute in windows phone
I need to consume the WCF from my windows phone app and it creates the proxy with the need of using System.Data and Servicemodel.XmlSerializerFormatAttribute.
I can't see 开发者_如何学Pythona way to add this namespace into this windows phone app? please help?
IExtensibleDataObject and ExtensionDataObject are not supported in Silverlight (therefore, not supported in a Windows Phone 7 Silverlight-based application).
You will have no problem using XmlSerializerFormatAttribute (as per MSDN), but your app should have a way around System.Data, since it is not supported.
In your case, what you should do is directly pass a service reference by adding it in your project.
Make sure you use the correct WCF service URL and it should work right away:
The namespace you are specifying will be the one you will use in the code-behind to access the service methods.
Probably, in your project, first you need to add reference to the System.Data and System.ServiceModel.
精彩评论