Jump to content

How to comment out an existing node in XML


bhumis
 Share

Recommended Posts

Hi everyone,

I have included and looked at the code of "_XMLDomWrapper.au3" and tried to use "_XMLUpdateField" function. This function works if i try to update a node value but giving an error to comment out an exising node.

This is my node and i have to comment out this entire node.

<displayFieldUUID name="businessunit">D079D2CC-4AB5-48D2-985B-94F7E55331D0</displayFieldUUID>

How do i comment out an existing node of XML file? The above node should look like this.

<!--<displayFieldUUID name="businessunit">D079D2CC-4AB5-48D2-985B-94F7E55331D0</displayFieldUUID>-->

Thanks!

Link to comment
Share on other sites

look into .createcomment, and add the outer XML of your node into it, then delete the node.

http://www.w3schools.com/dom/met_document_createcomment.asp

Edited by jdelaney
IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...