after update and values

johiot

New member
Local time
Today, 15:30
Joined
May 10, 2002
Messages
8
I have a combo box that i t takes values from a table.I put this code in the after update event.
"Private Sub combo_box1_AfterUpdate()
If Me.Combo_ box1.Value = 110 Then
DoCmd.OpenForm "frmthromvolytika", acNormal, , , acFormAdd
End If
End Sub"
The values are 110,111,112,113,114,115,116,117,118,119,120.
I want only for values 110,111,112,113 to take place the event How can i do this?
Thanks
 
Private Sub combo_box1_AfterUpdate()
Select Case Combo_ box1.Value
Case 110 to 113
DoCmd.OpenForm "frmthromvolytika", acNormal, , , acFormAdd
Case Else
Exit Sub
End Select
 
Thanks I'll try.If i want values 110,115,120 How can i do this;
 
Why not look up the syntax of the Case statement.
 

Users who are viewing this thread

Back
Top Bottom