OnePoint Consulting
New member
- Local time
- Today, 23:15
- Joined
- Apr 2, 2020
- Messages
- 15
Hi Guys,
i'm trying to get a command button to be disabled in it's default state and only to be enabled when the user enters values (text and Dates) into combo and text boxes.
i've tried following code in VBA but i haven't been successful yet… could someone help out?
Thanks in advance =)
The remaning Combo and text boxes are missing in the code, since i don't/wouldn't know how to "add" them…
i'm trying to get a command button to be disabled in it's default state and only to be enabled when the user enters values (text and Dates) into combo and text boxes.
i've tried following code in VBA but i haven't been successful yet… could someone help out?
Thanks in advance =)
Code:
private sub Command1_Click()
if Me.ComboFirma.Value = Null Then
Me.Command1.Enabled = False
Else
Me.Command1.Enabled = True
End if
'Run Query
DoCmd.OpenQuery "Query1"
End Sub
The remaning Combo and text boxes are missing in the code, since i don't/wouldn't know how to "add" them…