Type | Description | |||
Item as Variant | A long expression that indicates the handle of the item. | |||
ColIndex as Variant | A long expression that indicates the column's index, a string expression that indicates the column's key or the column's caption. | |||
AlignmentEnum | An AlignmentEnum expression that indicates the alignment of the cell's caption. |
The following VB sample right aligns the focused cell:
With G2antt1.Items .CellHAlignment(.FocusItem, 0) = AlignmentEnum.RightAlignment End With
The following C++ sample right aligns the focused cell:
#include "Items.h" CItems items = m_g2antt.GetItems(); items.SetCellHAlignment( COleVariant( items.GetFocusItem() ), COleVariant( (long)0 ), 2 /*RightAlignment*/ );
The following VB.NET sample right aligns the focused cell:
With AxG2antt1.Items .CellHAlignment(.FocusItem, 0) = EXG2ANTTLib.AlignmentEnum.RightAlignment End With
The following C# sample right aligns the focused cell:
axG2antt1.Items.set_CellHAlignment(axG2antt1.Items.FocusItem, 0, EXG2ANTTLib.AlignmentEnum.RightAlignment);
The following VFP sample right aligns the focused cell:
with thisform.G2antt1.Items .DefaultItem = .FocusItem .CellHAlignment(0,0) = 2 && RightAlignment endwith