vangogh228
Registered User.
- Local time
- Today, 15:56
- Joined
- Apr 19, 2002
- Messages
- 302
I have a selection box with 13 choices. Each one makes visible a different legend. All legends are invisible otherwise. I am providing the code for the first 3 here, and wondering "Is there a better way of doing this?" Any help is appreciated. Tom
--------
Private Sub ViewLegend_AfterUpdate()
If ViewLegend = 1 Then
legendA.Visible = True
Else
legendA.Visible = False
End If
If ViewLegend = 2 Then
LegendB.Visible = True
Else
LegendB.Visible = False
End If
If ViewLegend = 3 Then
LegendC.Visible = True
Else
LegendC.Visible = False
End If
------------
etc until End Sub.
--------
Private Sub ViewLegend_AfterUpdate()
If ViewLegend = 1 Then
legendA.Visible = True
Else
legendA.Visible = False
End If
If ViewLegend = 2 Then
LegendB.Visible = True
Else
LegendB.Visible = False
End If
If ViewLegend = 3 Then
LegendC.Visible = True
Else
LegendC.Visible = False
End If
------------
etc until End Sub.