如何用jdom生成office生成的xml文件
注意,是生成!!
!xml文件样式如下所示,
  
<FILEREF>
<xml xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema">
<s:Schema id="RowsetSchema">
  <s:ElementType name="row" content="eltOnly" rs:updatable="true">
     <s:AttributeType name="Authority_No" rs:number="1" rs:write="true">
       <s:datatype dt:type="string" rs:dbtype="str" dt:maxLength="50" rs:precision="0" rs:maybenull="false" />
     </s:AttributeType>
  <s:ElementType>
<xml>
</FILEREF>

解决方案 »

  1.   

    这个就要看你是否了解office的xml格式了. 
    如果不了解的话, 还是用api吧. 
    比如apache的poi.
      

  2.   

    自己做太费劲了,
    用这个吧:
    http://openxml4j.org/因为office 2007的XML已经是标准,所以这方面的API也逐渐成熟了:OpenXML4J is a Java library dedicated to the creation and manipulation of Office Open XML (ECMA-376) and OPC based documents (for example Office 2007 Word, Excel and PowerPoint documents). OpenXML4J provides you a way to create and manipulate Open XML documents for a bunch of scenarios without using any office suite.
      

  3.   

    (*^__^*) 嘻嘻……,自己研究了一下,用jdom还是很方便的