我使用的是Delphi 2010,只有库存标准VCL库。目标系统是 win32。
如果我引用了 IXMLDocument,如何获取 IXMLDocument 包装的底层对象的 IXMLDOMDocument2 接口?
function GetXMLDOMDocument2(const XMLDocument: IXMLDocument): IXMLDOMDocument2;
begin
Result := (XMLDocument.DOMDocument as IXMLDOMNodeRef).GetXMLDOMNode as IXMLDOMDocument2;
end;