Adobe 38043740 - ColdFusion Standard - Mac Development Manual page 1077

Developing applications
Hide thumbs Also See for 38043740 - ColdFusion Standard - Mac:
Table of Contents

Advertisement

DEVELOPING COLDFUSION 9 APPLICATIONS
Using Web Elements and External Objects
Type
Using a function
Property
StructDelete(xmlElemPath, propertyName)
Attribute
All attributes:
StructDelete(xmlElemPath, XmlAttributes)
A specific attribute:
StructDelete(xmlElemPath.XmlAttributes,"attributeName")
Child element
All children of an element:
StructDelete(xmlElemPath, "XmlChildren")
or
ArrayClear(xmlElemPath.XmlChildren)
All children with a specific name:
StructDelete(xmlElementpath,"elemName")
ArrayClear(xmlElemPath.elemName)
A specific child:
ArrayDeleteAt(xmlElemPath.XmlChildren,position)
ArrayDeleteAt(xmlElemPath.elemName,position)
Changing contents of an element
Use the following techniques to change the contents of an element:
Type
Using a function
Property
StructUpdate(xmlElemPath,"propert
yName", "value")
Attribute
StructUpdate(xmlElemPath.XmlAttri
butes,"attributeName", "value")
Child element
ArraySet(xmlElemPath.XmlChildren,
index,index, newElement)
(replace)
(use the same value for both index entries to
change one element)
Using an assignment statement
xmlElemPath.propertyName ="value"
xmlElemPath["propertyName"] ="value"
xmlElemPath.XmlAttributes.attributeName="value"
xmlElemPath.XmlAttributes["attributeName"] =
"value"
Replace first or only child named elementName:
parentElemPath.elementName =newElement
parentElemPath["elementName"]= newElement
Replace a specific child named elementName:
parentElemPath.elementName[index] = newElement
or
parentElemPath["elementName"][index] = newElement
Last updated 1/20/2012
Using an assignment statement
xmlElemPath.propertyName=""
Not available
Not available
1072

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfusion 9

Table of Contents