This documentation is archived and is not being maintained.

Visual Basic: DataGrid Control

Visual Studio 6.0

AllowSizing Property

See Also   Example   Applies To

Returns or sets a value indicating whether a user can resize columns or splits in the DataGrid control at run-time.

Syntax

object.AllowSizing [= value]

The AllowSizing property syntax has these parts:

Part Description
object An object expression that evaluates to an object in the Applies To list.
value A Boolean expression that determines whether a column or split can be resized, as described in Settings.

Settings

The settings for value are:

Setting Description
True (Default for Column) User can resize column or split.
False (Default for Split) User can't resize column or split.

Remarks

If the AllowSizing property is True, the mouse pointer turns into a double-headed (Size W E) arrow when positioned over the divider of the specified column, and the user can resize the column by dragging. Any change in column size causes a ColResize event.

For the leftmost split with AllowSizing set to True, the mouse pointer turns into a pair of vertical lines with a downward arrow when positioned over that split's size box (at the lower left corner), and the user can create a new split by dragging. The creation of a new split causes a SplitChange event.

If AllowSizing is True for any other split, the mouse pointer turns into a pair of vertical lines with a double-headed arrow when positioned over that split's size box, and the user can resize the split by dragging. No event is fired in this case (except for the standard mouse events).

Show: