Click here to Skip to main content
15,902,840 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
How can i use xml data without converting it into any other collection type in windows forms...???

What I have tried:

http://www.c-sharpcorner.com/blogs/how-to-use-a-web-service-in-windows-form-application1
https://msdn.microsoft.com/en-us/library/scf355x6%28v=vs.90%29.aspx
https://msdn.microsoft.com/library/ff855828(v=vs.100).aspx
Posted
Comments
dan!sh 16-Feb-16 1:48am    
What do you mean by use? What do you want to do with the XML?
Phahad Mirza 16-Feb-16 2:01am    
@Danish: i want to iterate the xml something like this
(foreach xmlvariable var in xmldatafromwebservices)
{
textbox1.text=var[0].ToString();
}
i donot want to do this.
Dataset ds=xmldatafromwebservices
textbox1.text=ds.tables[0].rows[0]["ColName"].ToString();
and all is required in Windows forms. i donot want to do it in Asp.Net.
Sergey Alexandrovich Kryukov 16-Feb-16 3:47am    
This is you who is supposed to tell us how you want to use the data and why, especially if you mention "without" something.
—SA

1 solution

Take a look at LINQ2XML classes and methods. Your starting method could be XElement.Parse to load the XML string.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900