Dim objDomElement As MSXML.IXMLDOMElement
Dim xDoc As New MSXML.DOMDocument
Set objDomElement = xDoc.createElement("ABC")
objDomElement.Text = "12345"
Debug.Print objDomElement.xml
我不知道你想怎样使用!所以随便写了一下,一般XML都要用CreatXXX来建立所要的东东!dim不能直接实现,MSXML.IXMLDOMNode等也是一样!