

| Type | Description | |||
| Position as Long | A long expression that indicates the position of the requested group | |||
| Group | A Group object being retrieved. |
The following VB sample enumerates the groups in the control, as they are displayed:
With ListBar1.Groups
Dim i As Long
For i = 0 To .Count - 1
With .ItemByPos(i)
Debug.Print (.Caption)
End With
Next
End With
The following C++ sample enumerates the groups in the control, as they are displayed:
CGroups groups = m_listbar.GetGroups();
for ( long i = 0; i < groups.GetCount(); i++ )
{
CGroup group( groups.GetItemByPos( i ) );
OutputDebugString( group.GetCaption() );
}
The following VB.NET sample enumerates the groups in the control, as they are displayed:
With AxListBar1.Groups
Dim i As Integer
For i = 0 To .Count - 1
With .ItemByPos(i)
Debug.WriteLine(.Caption)
End With
Next
End With
The following C# sample enumerates the groups in the control, as they are displayed:
for (int i = 0; i < axListBar1.Groups.Count; i++)
{
EXLISTBARLib.Group g = axListBar1.Groups.get_ItemByPos(i);
System.Diagnostics.Debug.WriteLine(g.Caption);
}
The following VFP sample enumerates the groups in the control, as they are displayed:
With thisform.ListBar1.Groups
local i
For i = 0 To .Count - 1
With .ItemByPos(i)
wait window nowait .Caption
EndWith
Next
EndWith