
842
|
Chapter 42: The System.Web.UI.WebControls Namespace
This is the Title of the Book, eMatter Edition
Copyright © 2008 O’Reilly & Associates, Inc. All rights reserved.
DataGridColumnCollection
System.Web.UI.WebControls (system.web.dll)
sealed class
This is the collection of DataGridColumn objects in a DataGrid control. It is provided through
the DataGrid.Columns property. You can use this collection to programmatically add or
remove columns, but these changes will not be automatically persisted over postbacks
because the DataGrid.Columns property is not stored in view state. This collection will only
contain columns that have been added through templates, not automatically gener-
ated ones.
Returned By
DataGrid.Columns
DataGridCommandEventArgs
System.Web.UI.WebControls (system.web.dll)
sealed class
The DataGridCommandEventArgs class provides more information for the ItemCommand, Cancel-
Command, DeleteCommand, EditCommand, and UpdateCommand events of the DataGrid control. This
information consists of an Item property identifying the affected DataGridItem and a
CommandSource property that refers to the button or hyperlink that was clicked. You have
to cast this object to an appropriate type to read its properties.
Hierarchy
System.Object ➝ System.EventArgs ➝ CommandEventArgs ➝
DataGridCommandEventArgs
public sealed class DataGridColumnCollection : ICollection, IEnumerable, System.Web.UI.IStateManager ...