Link Search Menu Expand Document

XmlDocument.CreateComment Method

Explanation Create a Comment node.
Not supported in Mobile, AI
Call format var comment = xmldoc.CreateComment( data )
Return value XmlComment object
Arguments String data Character string that be the initial value of the Comment node
Exception None
Example of use
    var domimpl = new XmlDOMImplementation;
    var res = session.Get("/test/sample.xml");
    var xmldoc = domimpl.Load(res);
    var comment = xmldoc.CreateComment("ABC");
    xmldoc.DocumentElement.AppendChild(comment);
    
Related item XmlComment class