Contents

cfgridcolumn

Description

Used with cfgrid in a cfform, you use cfgridcolumn to specify column data in a cfgrid control. Font and alignment attributes used in cfgridcolumn override any global font or alignment settings defined in cfgrid.

Category

Other

Implemented

Usage Syntax

<cfgridcolumn  
	name="String"
	[mask="String"]
	[header="String"]
	[width="number"]
	[font="String"]
	[fontSize="number"]
	[italic="Boolean"]
	[bold="Boolean"]
	[textColor="String"]
	[bgColor="String"]
	[href="String"]
	[hrefKey="String"]
	[target="String"]
	[select="Boolean"]
	[display="Boolean"]
	[type="String"]
	[headerFont="String"]
	[headerFontSize="number"]
	[headerItalic="Boolean"]
	[headerBold="Boolean"]
	[headerTextColor="String"]
	[dataAlign="String"]
	[headerAlign="String"]
	[numberFormat="String"]
	[values="String"]
	[valuesDisplay="String"]
	[valuesDelimiter="String"]
 />

[] = Optional attribute

Attributes

Name Type Required Default Description
name String Yes A name for the grid column element. If the grid uses a query, the column name must specify the name of a query column.
mask String No
header String No Text for the column header. The value of header is used only when the cfgrid colHeaders attribute is Yes (or omitted, since it defaults to Yes).
width number No The width of the column, in pixels. Default is the width of the column head text.
font String No Font name to use for data in the column. Defaults is the font specified by cfgrid.
fontSize number No Font size for text in the column. Default is the font specified by cfgrid.
italic Boolean No Yes or No. Yes displays all grid control text in italic. Default is as specified by the corresponding attribute of cfgrid.
bold Boolean No Yes or No. Yes displays all grid control text in boldface. Default is as specified by the corresponding attribute of cfgrid.
textColor String No Color value for grid element text in the grid column, or an expression you can use to manipulate text color in grid column elements. Valid color entries are: black (default), magenta, cyan, orange, arkgray, pink, gray, white, lightgray, yellow
bgColor String No Color value for the background of the grid column, or an expression you can use to manipulate grid column background color. Valid color entries are: black, magenta, cyan, orange, darkgray, pink, gray, white (default), lightgray, yellow.
href String No URL to associate with the grid item. You can specify a URL that is relative to the current page
hrefKey String No The name of a query column when the grid uses a query. The column specified becomes the Key regardless of the select mode for the grid.
target String No The name of the frame in which to open the link specified in href.
select Boolean No Yes or No. Yes lets end users select a column in a grid control. When No, the column cannot be edited, even if the cfgrid insert or delete attributes are enabled. The value of the select attribute is ignored if the cfgrid selectMode attribute is set to Row or Browse.
display Boolean No Yes or No. Use to hide columns. Default is Yes to display the column.
type String No
headerFont String No Font to use for the column header. Default is as specified by the corresponding attribute of cfgrid.
headerFontSize number No Font size to use for the column header, in pixels. Default is as specified by the orresponding attribute of cfgrid.
headerItalic Boolean No Yes or No. Yes displays column header text in italic. Default is as specified by the corresponding attribute of cfgrid.
headerBold Boolean No Yes or No. Yes displays header text in boldface. Default is as specified by the corresponding attribute of cfgrid.
headerTextColor String No Color value for the grid control column header text. Entries are: black (default), magenta, cyan, orange, darkgray, pink, gray, white, lightgray, yellow.
dataAlign String No Alignment for column data. Entries are: left, center, or right. Default is as specified by cfgrid.
headerAlign String No Alignment for the column header text. Default is as specified by cfgrid.
numberFormat String No The format for displaying numeric data in the grid. For information about mask characters, see "numberFormat mask characters".
values String No Formats cells in the column as drop down list boxes. lets end users select an item in a drop down list. Use the values attribute to specify the items you want to appear in the drop down list.
valuesDisplay String No Used to map elements specified in the values attribute to a string of your choice to display in the drop down list. Enter comma separated strings and/or numeric range(s).
valuesDelimiter String No Character to use as a delimiter in the values and valuesDisplay attributes. Default is "," (comma).

Example Usage