.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

Popular posts from this blog

MySql variables and php -

url rewriting - How to implement the returnurl like SO in PHP? -

Which Python client library should I use for CouchdB? -