CellWidth

This property returns the width of the current cell.

Syntax

object.CellWidth [= number]

Parameters

object
Object expression that evaluates to a Grid control.
number
Numeric expression specifying the width of the current cell.

Remarks

The CellWidth property is unavailable at design time and read-only at run time.

This property is useful if you want to emulate in-cell editing. By trapping the KeyPress event of the Grid control, you can place a text box or some other control over the current cell and let the user edit its contents.

The return values are always in twips, regardless of the form's ScaleMode setting.