Vishwamohan

Welcome to Vishwa's blog - Technology, Spirituality and More...

Parsing XML with multiple namespaces

You may come across a situation when you will have to read a XML document containing name spaces and assign values to it. Here is sample which includes multiple namespaces with SOAP envelope xml document. [More]

Create XML Data file with Element vs. Attribute Format

You can choose to create a XML file in which detail records are represented as Elements or Attributes only. It is wiser to use the best use of both, more use of attribute reduces the size of xml file and increases the speed over wire. Representation of data in Elements only XML file becomes heavier in file size thus slower the transmission. The only benefit is when you open this file in browser it is relatively easily to read. Following are an example for creating a file with same information in two different ways. [More]

Using XMLWriter and XMLReader

This is a simple example for demonstrating how to use XMLReader or XMLWriter for reading or writing a XML file or XML String. I am using a Customer Entity which was created in previous examples. [More]

XML String, Dataset and Class Manipulation

I have written some useful ready to use functions in a Helper Class which can be used in XML string manipulation. These functions include following abilities :

Get XML data string from/to a class

Set/Remove CDATA in XML String

Clear All/Limited Special Characters from XML string

Set/Remove Root Node to XML String

Get Inner XML/Text on Relative Path

Get XML Document to/from an object

Get Custom Dataset from/to XML string


[More]