Tab

ASPxPopupControl.WindowDataBound Event

Occurs after a popup window has been bound to a data source.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v21.1.dll

Declaration

public event PopupWindowEventHandler WindowDataBound

Event Data

The WindowDataBound event's data class is PopupWindowEventArgs. The following properties provide information specific to this event:

Property Description
Window Gets a popup window object related to the event.

Remarks

The WindowDataBound event is raised for each popup window after it’s data bound to the corresponding data from the specified data source. This event enables you to customize settings the related popup window before it is finally rendered. Handling the WindowDataBound event correctly you can, for example, implement a custom logic to dynamically map properties of a popup control’s windows to the required data fields.

The processed popup window can be accessed by using the PopupWindowEventArgs.Window property of the event’s argument.

If the control functions in unbound mode, the WindowDataBound event isn’t raised.

Example

The following example demonstrates how you can handle the WindowDataBound event, to bind the PopupWindow’s FooterText property to the Suite attribute manually

The image below shows the result.

ASPxPopupControl - WindowDataBound

protected void ASPxPopupControl1_WindowDataBound(object source, DevExpress.Web.PopupWindowEventArgs e) {
        e.Window.FooterText = DataBinder.Eval(e.Window.DataItem, "Suite").ToString();

}
See Also