XMLÈ¡ÖµÓ¦ÓÃʵÀý
ÔÌù£ºhttp://topic.csdn.net/u/20100412/14/f6941844-e9bf-4ed7-a0c2-bef03d775783.html?70615
declare @data xml=
'<root>
<SaleMan>
<SaleManId>1</SaleManId>
<SaleManCode>001</SaleManCode>
<Nodes>
<Node>
<NodeId>101</NodeId>
<NodeCode>101</NodeCode>
<CardSetting>
<R1>1</R1>
<R2>2</R2>
<R3>3</R3>
</CardSetting>
</Node>
<Node>
<NodeId>102</NodeId>
<NodeCode>102</NodeCode>
<CardSetting>
<R1>1</R1>
<R2>2</R2>
<R3>3</R3>
<R8>0</R8>
</CardSetting>
</Node>
<Node>
<NodeId>103</NodeId>
<NodeCode>103</NodeCode>
<CardSetting>
<R1>1</R1>
<R2>2</R2>
<r3>3</r3>
</CardSetting>
</Node>
</Nodes>
</SaleMan>
<SaleMan>
<SaleManId>2</SaleManId>
<SaleManCode>002</SaleManCode>
<Nodes>
<Node>
<NodeId>101</NodeId>
<NodeCode>101</NodeCode>
<CardSetting>
<R1>5</R1>
<R2>7</R2>
<R3>4</R3>
<R8>3</R8>
</CardSetting>
</Node>
</Nodes>
</SaleMan>
<SaleMan>
<SaleManId>3</SaleManId>
<SaleManCode>003</SaleManCode>
<Nodes>
<Node>
<NodeId>101</NodeId>
<NodeCode>101</NodeCode>
<CardSetting>
<R1>4</R1>
&
Ïà¹ØÎĵµ£º
1.route.xmlÎļþÄÚÈÝ
<?xml version="1.0" encoding="GBK"?>
<root>
<route id="1111">
<id>111</id>
<name>ËÄ´¨</name>
<path>www.baidu.com/hehe.html</path>
</route>
</root>
2.test.html´úÂë
<html>
<body>
<script> ......
¶ÔXmlµÄ½Úµã½øÐмòµ¥²éѯµÄʱºò£¬³£ÓõĿÉÒÔʹÓÃÈçÏ·½·¨£º
(1) XmlNode node = doc.selectSingleNode("//AllNode/Node[@ID = ’aaa’]");
ÔÚÕû¸öXmlÖвéÕÒAllNode½ÚµãϵĽڵãÃûΪNodeµÄ½Úµã£¬¸Ã×Ó½ÚµãµÄIDÊôÐÔֵΪaaa
(2)XmlNode node = doc.selectSingleNode("//AllNode /*[@ID = ’aaa& ......
string file = "c:\\work.xml";
private void btnCearte_Click(object sender, EventArgs e)
{
XmlDocument doc = new XmlDocument();
  ......
ʲôÊÇ XML?
XML Ö¸¿ÉÀ©Õ¹±ê¼ÇÓïÑÔ£¨EXtensible Markup Language£©
XML ÊÇÒ»ÖÖ±ê¼ÇÓïÑÔ£¬ºÜÀàËÆ HTML
XML µÄÉè¼Æ×ÚÖ¼ÊÇ´«ÊäÊý¾Ý£¬¶ø·ÇÏÔʾÊý¾Ý
XML ±êǩûÓб»Ô¤¶¨Òå¡£ÄúÐèÒª×ÔÐж¨Òå±êÇ©¡£
XML ±»Éè¼ÆΪ¾ßÓÐ×ÔÎÒÃèÊöÐÔ¡£
XML ÊÇ W3C µÄÍƼö±ê×¼
XML Óë HTML µÄÖ÷Òª²îÒì
XML ²»ÊÇ HTML µÄÌæ´ú¡£
XML ºÍ HTML Ϊ² ......