For an Windows Phone 8 Application, I need to connect to a Web Service. But when I use the Visual tool to add the service reference, it adds a file "Reference.cs" with an error :
'System.ServiceModel.XmlSerializerFormatAttribute' does not contain a definition for 'Style'
listen i had the same problem, so i added another attribute [System.ServiceModel.DataContractFormat(Style=System.ServiceModel.OperationFormatStyle.Rpc)]
any ways the service gave an error that i can't have both attributes
[System.ServiceModel.XmlSerializerFormatAttribute(SupportFaults=true)] [System.ServiceModel.DataContractFormat(Style=System.ServiceModel.OperationFormatStyle.Rpc)] so when i removed the XmlSerializerFormatAttribute and just left datacontractformate it returned the desired object (response )but with all values = null when i removed the DataContractFormat it returned null not even an empty object so i had to call this service form my code using httpclient.postasync and passing the soap xml to it, if u need more details let me know good luck :)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With