Read up on "EnumGroup()" in the manual, which includes a simple example.