Skip to content

AllowColumnRemove Property

Description

Specifies whether GridColumns can be removed from the GridControl.

Property Type

Read-write property

Syntax (Visual Basic)

Public Property AllowColumnRemove() As Boolean

Remarks

If True, the column headers can be removed from the GridControl. To remove a column, the column header must be clicked on and dragged to an area on the screen that does not have any column headers and is not the Group By box (i.e., dragging the column header over the rows or over the toolbar). When the column header is over an area that the column can be removed, an "X" will be displayed over the column header indicating that you can drop the column header and it will be removed.

Column Remove Indicator

Once a column is removed, the Visible property is set to False. To replace the column, set the Visible property to True, or drag the column header from the FieldChooser if ShowInFieldChooser is True for the column.

If False, the "X" will never appear, and it does not matter where the column is dropped; it will not be removed.

Example

AllowColumnRemove Sample (Visual Basic)

This sample illustrates how to disable column removal.

' This will not allow columns to be removed by a drag and drop
wndGridControl.AllowColumnRemove = False

See Also


Copyright (c) 1998-2024 Codejock Technologies. All rights reserved.