walid mousbah

walid mousbah

  • NA
  • 10
  • 11.9k

XML into Object

Jun 27 2015 6:59 AM
I'm trying to deserialize my xml this way: 
public static T MyMethod<T>(this string Myxml)
{
XmlDocument Mydocument = new XmlDocument();
using (XmlTextReader XmlTr = new XmlTextReader(new StringReader(Myxml)))
{
Mydocument.Load(XmlTr);
}
// How do I return the result ?
return ???
}
How do I return my result into MyObject which I created to represent the XML ?
Thanks

Answers (1)