cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
479
Views
5
Helpful
0
Replies

Add/Remove entry to XML doc from CCX script

JacobMunson
Level 1
Level 1

I am working on a CCX script where I need to add and remove entries from an XML document. The XML document will have a single root element with several child elements that need to be added and removed. Is there a way to append a new child element to the root?

 

Example:

Simple XML to start

<reservations>

 <reservation>

  <name>John</name>

 </reservation>

</reservations>

 

in the script I need to add another reservation to the bottom so it looks like this.

<reservations>

 <reservation>

  <name>John</name>

 </reservation>

 <reservation>

  <name>Jill</name>

 </reservation>

</reservations>

 

I will then need to remove an element from the script so that after the removal it looks like. 

<reservations>

 <reservation>

  <name>Jill</name>

 </reservation>

</reservations>

 

0 Replies 0