Three ways to load Xml to XmlDocument : XmlDocument « XML « C# / CSharp Tutorial

Home
C# / CSharp Tutorial
1.Language Basics
2.Data Type
3.Operator
4.Statement
5.String
6.struct
7.Class
8.Operator Overload
9.delegate
10.Attribute
11.Data Structure
12.Assembly
13.Date Time
14.Development
15.File Directory Stream
16.Preprocessing Directives
17.Regular Expression
18.Generic
19.Reflection
20.Thread
21.I18N Internationalization
22.LINQ
23.GUI Windows Forms
24.Windows Presentation Foundation
25.Windows Communication Foundation
26.Workflow
27.2D
28.Design Patterns
29.Windows
30.XML
31.XML LINQ
32.ADO.Net
33.Network
34.Directory Services
35.Security
36.unsafe
C# / C Sharp
C# / C Sharp by API
C# / CSharp Open Source
C# / CSharp Tutorial » XML » XmlDocument 
30.8.10.Three ways to load Xml to XmlDocument
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Xml;
using System.IO;

    public class MainClass
    {
        public static void Main()
        {
            try
            {
                XmlDocument doc = new XmlDocument();
                doc.Load("");

//                FileStream stream = new FileStream(textBox1.Text, FileMode.Open);
  //              doc.Load(stream);
    //            stream.Close();

      //          doc.LoadXml(textBox1.Text);
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
    }
30.8.XmlDocument
30.8.1.XmlDocument Event: node changed, node inserted and node removed
30.8.2.Add attribute to Xml document
30.8.3.Read Write Xml
30.8.4.Remove child from XmlDocument
30.8.5.Get child count
30.8.6.Get element by tag name
30.8.7.Get value from selected node
30.8.8.Loop Through XmlDocument Recursively
30.8.9.Select Root
30.8.10.Three ways to load Xml to XmlDocument
30.8.11.Fast select by ID using DOM API
30.8.12.Create Node and append to XmlDocument
30.8.13.Select nodes from xml document
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.