Check Boxes

M

Majic

Hey Guys,
I created a form that have 2 check boxes, one for Pass and the other
for Fail. I have both boxes unchecked, however I would like the user
to have to select one or the other before they go to next record.

If anyone could help please let me know

Thank you
 
S

scubadiver

Put this in the "Before update" event in the form properties. Should work

If IsNull(Me!checkbox1) or IsNull(Me!checkbox2) Then
MsgBox "You must fill in a checkbox", vbCritical
Cancel = True
End If
 
S

scubadiver

Just thought. Why do you have two checkboxes? Why not have one so "true" is
far pass and "false" is for fail (ticked and unticked)

If your checkbox is based on a score, you can use the afterupdate event in
the score field to tick the box automatically

If score>60 then me.checkbox.value = true ??? Something like that :)

If you make it read only and disable it then you won't have to worry about it.
 
J

John W. Vinson

Hey Guys,
I created a form that have 2 check boxes, one for Pass and the other
for Fail. I have both boxes unchecked, however I would like the user
to have to select one or the other before they go to next record.

If anyone could help please let me know

Thank you

Did you even bother to read the three replies offering much better solutions?

John W. Vinson [MVP]
 
S

scubadiver

What solutions are they, may I ask??



John W. Vinson said:
Did you even bother to read the three replies offering much better solutions?

John W. Vinson [MVP]
 
J

Jeff Boyce

Option group, Yes/No field, Text field (yes/no/unanswered)

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
M

Majic

Put this in the "Before update" event in the form properties. Should work

If IsNull(Me!checkbox1) or IsNull(Me!checkbox2) Then
MsgBox "You must fill in a checkbox", vbCritical
Cancel = True
End If

--www.ae911truth.org







- Show quoted text -

I will try this thank you so much and let you know if it works for me.

Thank you
 
M

Majic

Did you even bother to read the three replies offering much better solutions?

John W. Vinson [MVP]

I read all solutions and I am trying them, so far it did not work for
me. I am trying some more.
Thank you
 
M

Majic

Put this in the "Before update" event in the form properties. Should work

If IsNull(Me!checkbox1) or IsNull(Me!checkbox2) Then
MsgBox "You must fill in a checkbox", vbCritical
Cancel = True
End If

--www.ae911truth.org







- Show quoted text -

Thank but it did not work.
 
J

John W. Vinson

Thank but it did not work.


"Doctor, I don't feel good, what should I take?"

Please tell us what you did and in what way it didn't work. We cannot fix a
problem that we cannot see.

John W. Vinson [MVP]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top