ASPxGridView.HtmlEditFormCreated Event
Occurs when a table row, which corresponds to the Edit Form, has been created.
Namespace: DevExpress.Web
Assembly: DevExpress.Web.v24.2.dll
Declaration
Event Data
The HtmlEditFormCreated event's data class is ASPxGridViewEditFormEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
EditForm | Gets the web control that represents the Edit Form. |
Remarks
If the GridViewEditingMode.PopupEditForm mode is enabled, the ASPxGridView.HtmlRowCreated event, which enables you to initialize editors contained within the Edit Form template, isn’t raised. In this instance, you should handle the HtmlEditFormCreated event. The web control, which represents the Edit Form can be accessed via the event parameter’s EditForm property.
protected void ASPxGridView1_HtmlEditFormCreated(object sender,
DevExpress.Web.ASPxGridViewEditFormEventArgs e) {
Control wc = ASPxGridView1.FindEditFormTemplateControl("ASPxButtonEdit1");
if (wc != null) {
ASPxButtonEdit templateEdit = wc as ASPxButtonEdit;
//
// Initialize the editor as required
//
templateEdit.ForeColor = System.Drawing.Color.Blue;
}
}
See Also