Field data type | GroupOn setting | GroupInterval setting |
All | Each value | (Default) Set to 1. |
Text | Prefix characters | Set to 3 for grouping by the first three characters in the field (for example, Chai, Chartreuse, and Chang would be grouped together). |
Date/Time | Week | Set to 2 to return data in biweekly groups. |
Date/Time | Hour | Set to 12 to return data in half-day groups. |
Private Sub Report_Open(Cancel As Integer)
' Set SortOrder property to ascending order.
Me.GroupLevel(0).SortOrder = False
' Set GroupOn property.
Me.GroupLevel(0).GroupOn = 1
' Set GroupInterval property to 1.
Me.GroupLevel(0).GroupInterval = 1
' Set KeepTogether property to With First Detail.
Me.GroupLevel(0).KeepTogether = 2
End Sub