readxml

How do I find out if a column exists in a VB.Net DataRow

I am reading an XML file into a DataSet and need to get the data out of the DataSet. Since it is a user-editable config file the fields may or may not be there. To handle missing fields well I'd like to make sure each column in the DataRow exists and is not DBNull. I already check for DBNull but I don't know how to make sure the column...

How do I improve performance of DataSet.ReadXml if I'm using a schema?

I'm have a ADO DataSet that I'm loading from its XML file via ReadXml. The data and the schema are in separate files. Right now, it takes close to 13 seconds to load this DataSet. I can cut this to 700 milliseconds if I don't read the DataSet's schema and just let ReadXml infer the schema, but then the resulting DataSet doesn't contai...

Read XML Node

hi, I want to read an specific xml node and it's value for example <customers> <name>John</name> <lastname>fetcher</lastname> </customer> and my code behind should be some thing like this ( I don't know how it should be tho :)) Response.Write(xml.Node["name"].Value) blah blah. As I said It's just an example cuz I don't know how t...

how can I read an xml attribute using readXML? how does dataset.readxml translate into tables?

I just want to know how does the table resulting from readXML look like, say if the xml file looks like this: <item attr="some attribute"> <descirption>anything</description> </item> I can reference tables directly by the Tables collection like this: ds.ReadXml(xml); ... ds.Tables[i] then I can access rows and columns using the row...

Problem with node.GetElementsByTagName in C#

I have a really simple XML file that I'm trying to read, but I can't seem to get it working. Here is the XML file: <?xml version="1.0"?> <Results><One>45364634</One><Two>-1</Two><Three>B</Three></Results> I am trying to get the contents of two like this: XmlNode node = doc.DocumentElement.SelectSingleNode("/Results/Two"); or Xml...

C# WinForms Read XML File - Only Specific Nodes.....

I have an XML File: <Database> <SMS> <Number>+447761692278</Number> <DateTime>2009-07-27T15:20:32</DateTime> <Message>Yes</Message> <FollowedUpBy>Unassigned</FollowedUpBy> <Outcome></Outcome> <Quantity>0</Quantity> <Points>0</Points> </SMS> <SMS> <Number>+447706583066</Number> <DateTime>...

Implementing IXmlSerializable for content containing data with or without CDATA tags

I am trying to figure out a way to parse an xml tag where content is passed in with CDATA tags for some input, but not for all. For example, the following is sample content I would receive for data which contains CDATA tags. But there is some other scenarios where the CDATA tags are ommited. <Data><![CDATA[ <h1>CHAPTER 2<br/> EDUCATION...

Undefined datatype: 'token'

Scenario: I am trying to collect information from xml file. To do so, i am using the xmlschema provided. plan is to readxmlschema against dataset and later read xml file. Please suggest me best process if the existing is not appropriate. Anways during this process i encountered this following issue. I am trying to readxmlschema into a d...