aspnet-devexpress-dot-web-dot-aspxcardview-dc8a2c50.md
Enables initializing the cell editors displayed within the edit cells.
Namespace : DevExpress.Web
Assembly : DevExpress.Web.v25.2.dll
NuGet Package : DevExpress.Web
public event ASPxCardViewEditorEventHandler CellEditorInitialize
Public Event CellEditorInitialize As ASPxCardViewEditorEventHandler
The CellEditorInitialize event's data class is ASPxCardViewEditorEventArgs. The following properties provide information specific to this event:
| Property | Description |
|---|---|
| Column | Gets the data column whose cell editor is being initialized. |
| Editor | Gets the editor currently being processed. Inherited from ASPxGridEditorEventArgs. |
| KeyValue | Gets the card key value - an object that uniquely identifies the card. |
| Value | Gets the editor’s value. Inherited from ASPxGridEditorEventArgs. |
| VisibleIndex | Gets the edited card’s visible index. |
The CellEditorInitialize event is raised when the ASPxCardView is switched to edit mode and enables you to initialize cell editors.
Note
The following example illustrates how to use the CellEditorInitialize event to automatically focus the required column’s editor using the editor’s ASPxWebControl.Focus method (the e.Editor event argument).
This example demonstrates how to prevent an end-user from changing the unit price. To do this, the CellEditorInitialize event is handled. If the processed edit cell corresponds to a column bound to the ‘UnitPrice’ data field, its editor’s ReadOnly property is set to true.
See Also