创建xml文档对象
To create a new document object, you must create a new instance of Msxml2.DOMDocument
.
JScript
The following code is in Microsoft® JScript®.
var xmlDoc = new ActiveXObject("Msxml2.DOMDocument.5.0");
|
VBScript
The following code is in Microsoft Visual Basic® Scripting Edition (VBScript).
Set xmlDoc = CreateObject("Msxml2.DOMDocument.5.0")
|
After you create the DOMDocument
object, you can set flags on it for different kinds of parsing and processing behavior, load XML documents, create new nodes inside the document to build an XML document from within your program, or persist your DOMDocument
object as an XML file。