Back to Devexpress

AlertControl.FormLoad Event

windowsforms-devexpress-dot-xtrabars-dot-alerter-dot-alertcontrol-4340a302.md

latest2.1 KB
Original Source

AlertControl.FormLoad Event

Fires after an alert window has been created, and allows you to customize the window and window’s buttons.

Namespace : DevExpress.XtraBars.Alerter

Assembly : DevExpress.XtraBars.v25.2.dll

NuGet Package : DevExpress.Win.Navigation

Declaration

csharp
[DXCategory("Events")]
public event AlertFormLoadEventHandler FormLoad
vb
<DXCategory("Events")>
Public Event FormLoad As AlertFormLoadEventHandler

Event Data

The FormLoad event's data class is DevExpress.XtraBars.Alerter.AlertFormLoadEventArgs.

Remarks

The event’s parameters allow you to access and customize the currentlly displayed alert window and the window’s buttons.

Example

The following example shows how to pin an alert window when it’s displayed. The AlertControl.FormLoad event is handled to perform window customization. To pin the window, the AlertButton.SetDown method is called for the AlertButtonCollection.PinButton.

csharp
using DevExpress.XtraBars.Alerter;

private void alertControl1_FormLoad(object sender, AlertFormLoadEventArgs e) {
    e.Buttons.PinButton.SetDown(true);
}
vb
Imports DevExpress.XtraBars.Alerter

Private Sub AlertControl1_FormLoad(ByVal sender As System.Object, ByVal e As AlertFormLoadEventArgs) _
Handles AlertControl1.FormLoad
    e.Buttons.PinButton.SetDown(True)
End Sub

See Also

AlertControl Class

AlertControl Members

DevExpress.XtraBars.Alerter Namespace