.net - How to use LINQ with ServiceModel.Channels.Message -
How can I use LINM with the service model? Channel. message? I want LINQ to use SOAP message body.
I tried to do this initially:
XElement elem = XElement.load (message.GetReaderAtBodyContents ());
But the piece of code complains that XMLReader should have EOF after the reading process. What is the right way to do this?
OK, I think I found a solution:
XDocument Document = XDocument.Parse (message.GetReaderAtBodyContents (). ReadOuterXml ());
Comments
Post a Comment