User Guide

Table Of Contents
ColdFusion XML format 723
</xf:choices>
</xf:select1>
</xf:group>
cfgrid tags
ColdFusion MX represents a cfgrid tag using the cf:grid XML tag. This tag has four
attributes:
format, which can be Flash, Applet, or XML; and the id, name, and bind attributes,
which all have the value of the
cfgrid tag name attribute.
For applet and Flash format grids, ColdFusion inserts
cfgrid controls in the XML as HTML
embed objects in <![CDATA[ sections in the body of a
cf:grid tag. The controls can be Java
applets or in SWF file format.
For XML format grids, ColdFusion converts the CFML to XML in the following format:
cf:grid bind="gridname" name="gridname" format="xml" id="gridname>
<metadata>
<cfgridAttribute1>attributeValue</cfgridAttribute1>
...
(There are an entry for attributes with a specified or default value.)
</metadata>
<columns>
<column cfgridcolumnAttribute1="value" ... />
...
</columns>
<rows>
<row>
<column1Name>row1Column1Value</column1Name>
<column2Name>row1Column2Value</column2Name>
...
</row>
<row>
<column1Name>row2Column1Value</column1Name>
<column2Name>row2Column2Value</column2Name>
</row>
...
</rows>
</cf:grid>
The following example shows a minimal grid with two nodes.
CFML
<cfgrid name="mygrid" Format="xml" selectmode="Edit" width="350">
<cfgridcolumn name="CorName" header="Course Name" >
<cfgridcolumn name="Course_ID" header="ID">
<cfgridrow data="one0,two0">
<cfgridrow data="one1,two1">
</cfgrid>