XmlElement x = objXmlDocument.documentElement;
You might need this if you are creating a WCF service that accepts XElement as parameter but user has a dataset to be converted to Xelement
XmlDocument xDoc = new XmlDataDocument(YourDataset);
XmlElement x = xDoc.DocumentElement;
example:You might need this if you are creating a WCF service that accepts XElement as parameter but user has a dataset to be converted to Xelement
XmlDocument xDoc = new XmlDataDocument(YourDataset);
XmlElement x = xDoc.DocumentElement;
DataSet ds = new DataSet();
ds.Tables.Add("students"); ds.Tables[0].Columns.Add("Name");
DataRow dr1 = ds.Tables[0].NewRow(); dr1[0] = "Alan"; ds.Tables[0].Rows.Add(dr1);
XmlDocument xDoc = new XmlDataDocument(ds);
XmlElement x = xDoc.DocumentElement;
That will actually return an XmlElement, not an XElement (which you can then pass to the web service)
ReplyDeleteThanks G-man. I've rectified example.
DeleteMy brother recommenԁed I would possiblу like
ReplyDeletethis websitе. Hе was once totally rіght.
This publish truly made my dаy. You can not bеliеѵе just
how muсh time I had spent for this info! Thank yоu!
my page > v2 cigs 15 coupon code
Thanks for liking blog. Quite encouraging!
ReplyDeleteNice blog here! Also уour wеbsіte loadѕ uр faѕt!
ReplyDeleteWhat web host are you using? Ϲan I get your аffіliаte linκ tο your host?
I ωish my ѕite loadеԁ up as quiсkly aѕ уourѕ lol
My blog post : v2 cig coupons