asp.net.ph

TemplateColumn Class

System.Web.UI.WebControls Namespace


Renders a column in a DataGrid that allows customizing the layout of controls in the column.

TemplateColumn Class Members

Collapse   Constructors

Visibility Constructor Parameters
public TemplateColumn ( )

Collapse   Properties

Visibility Name Value Type Accessibility
public EditItemTemplate ITemplate [ Get , Set ]
public FooterTemplate ITemplate [ Get , Set ]
public HeaderTemplate ITemplate [ Get , Set ]
public ItemTemplate ITemplate [ Get , Set ]

Collapse   Methods

Visibility Name Parameters Return Type
public InitializeCell ( TableCell cell , Int32 columnIndex , ListItemType itemType ) Void

Remarks

Use the TemplateColumn type in a DataGrid control to create a column with a customized control layout.

You can provide a custom appearance for the heading section, the footer section, and items section of the column by using the HeaderTemplate, FooterTemplate, and ItemTemplate properties, respectively.

You can also control how an item being edited is displayed in the TemplateColumn by setting the EditItemTemplate property.

Example

The following example demonstrates using a TemplateColumn in a DataGrid to display images bound to a field in the data source.

 Show me 

See Also

DataGrid   BoundColumn   ButtonColumn   EditCommandColumn   HyperLinkColumn Skip Navigation Links




Home
Suggested Reading


Previous page Back to top Next page

© 2000-2010 Rey Nuñez All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note

You can help support asp.net.ph