xml问题,大家帮帮我啊.
我想读取xml中的数据.但是读取的时候要把他的属性值一起放入到一个表中. 
 我在网上查了查.但是看的是一头雾水.请好心人给点代码研究研究.谢啦! 
 xml如下 
  <data   name=1>  
  <value> a </value>  
  <Comment> b </Comment>  
  <type> c </type>  
  <mimetype> d </mimety>  
  </data>  
  <data   name=2>  
  <value> q </value>  
  <Comment> q </Comment>  
  <type> e </type>  
  <mimetype> d </mimety>  
  </data>    
 我想得到的结果就是一个表 
 表如下 
 1 a         b         c            d 
 2         q         q         e            d 
 请大家帮忙啊
------解决方案--------------------Xml格式不正确
XML code
<?xml version="1.0" encoding="utf-8"?>
<root>
<data   name=1> 
<value> a </value> 
<Comment> b </Comment> 
<type> c </type> 
<mimetype> d </mimety> 
</data> 
<data   name=2> 
<value> q </value> 
<Comment> q </Comment> 
<type> e </type> 
<mimetype> d </mimety> 
</data> 
</root>