The event handler receives an argument of type System.EventArgs containing data related to this event.
The Close button's visibility is controlled by the HeaderButtons, HeaderButtonsShowMode and ClosePageButtonShowMode properties.
By default, clicking this button has no effect. You can handle the CloseButtonClick event to implement an appropriate behavior (for instance, hide the currently active tab page).
The event's e parameter represents an instance of the ClosePageButtonEventArgs class. It provides information on the page whose Close button has been clicked.

Example
The following example shows how to hide tab pages in the XtraTabControl when their Close buttons are clicked. To respond to clicking Close buttons, the CloseButtonClick event is handled.
C# |
using DevExpress.XtraTab;
using DevExpress.XtraTab.ViewInfo;
private void xtraTabControl1_CloseButtonClick(object sender, EventArgs e) {
ClosePageButtonEventArgs arg = e as ClosePageButtonEventArgs;
(arg.Page as XtraTabPage).PageVisible = false;
}
|
VB |
Imports DevExpress.XtraTab
Imports DevExpress.XtraTab.ViewInfo
Private Sub XtraTabControl1_CloseButtonClick(ByVal sender As System.Object, _
ByVal e As System.EventArgs) Handles XtraTabControl1.CloseButtonClick
Dim arg As ClosePageButtonEventArgs = TryCast(e, ClosePageButtonEventArgs)
TryCast(arg.Page, XtraTabPage).PageVisible = False
End Sub
|