Connecting Tech Pros Worldwide Forums | Help | Site Map

radio button/combobox focus

Brian Campbell
Guest
 
Posts: n/a
#1: Jan 6 '06
I have some code that may be of some help to us newbies. It is for when
you have a form with say two radio buttons, each activating/focusing
its respective combo box and making its initial value null. Note the
"fra" indicating all is within a frame. Note also in radio button
properties they have a value that sets the case numbers below.

Select Case Me.fraThisFrame.Value
Case 1
With Me.cboFirstOne
.Enabled = True
.Value = ""
.SetFocus
End With
With Me.cboSecondOne
.Enabled = False
.Value = ""
End With
Case 2
With Me.cboFirstOne
.Enabled = False
.Value = ""
End With
With Me.cboSecondOne
.Enabled = True
.Value = ""
.SetFocus
End With
End Select
End Sub


Closed Thread


Similar Microsoft Access / VBA bytes