

| Type | Description | |||
| Index as Long | A long expression that specifies the index of item. | |||
| ColIndex as Variant | A long expression that specifies the index of column, a string expression that identifies the column's caption or column's key. | |||
| Boolean | A boolean expression that specifies whether the cell contains radio button. |
The following VB sample enumerates all the cells in the first column and groups all of them in the same radio:
Dim h As Variant
List1.BeginUpdate
With List1.Items
For Each h In List1.Items
.CellHasRadioButton(h, 0) = True
.CellRadioGroup(h, 0) = 1234
Next
End With
List1.EndUpdate
or
Dim h As Variant
With List1
.BeginUpdate
.Columns(0).Def(exCellHasRadioButton) = True
With List1.Items
For Each h In List1.Items
.CellRadioGroup(h, 0) = 1234
Next
End With
.EndUpdate
End With
The following VB sample assigns a radio button to the focused cell:
With List1.Items
.CellHasRadioButton(.FocusItem, 0) = True
.CellRadioGroup(.FocusItem, 0) = 1234
End With
The following C++ sample assigns a radio button to the focused cell:
#include "Items.h" CItems items = m_list.GetItems(); items.SetCellHasRadioButton( items.GetFocusItem(), COleVariant( (long)0 ), TRUE ); items.SetCellRadioGroup( items.GetFocusItem(), COleVariant( (long)0 ), 1234 );
The following VB.NET sample assigns a radio button to the focused cell:
With AxList1.Items
.CellHasRadioButton(.FocusItem, 0) = True
.CellRadioGroup(.FocusItem, 0) = 1234
End With
The following C# sample assigns a radio button to the focused cell:
axList1.Items.set_CellHasRadioButton(axList1.Items.FocusItem, 0, true); axList1.Items.set_CellRadioGroup(axList1.Items.FocusItem, 0, 1234);
The following VFP sample assigns a radio button to the focused cell:
with thisform.List1.Items .CellHasRadioButton(.FocusItem,0) = .t. .CellRadioGroup(.FocusItem,0) = 1234 endwith