option group - default value

  • Thread starter sheniece via AccessMonster.com
  • Start date
S

sheniece via AccessMonster.com

I have 2 check boxes in an option group, I have 1 check box for yes and
another for no, when i start typing in a field the no check box automatically
gets checked, I tried to set the default option group value to isNull but
the check keeps appearing in the no box.
 
A

Allen Browne

Is you option group bound to a yes/no field from your table?

If so, the problem is that Access does not support Null in yes/no fields, so
as soon as you start entering something, the yes/no field becomes False.

Presumably the one text box has the Option Value 0 (for False), and the
other one has the Option Value or -1 (for True.)
 
S

sheniece via AccessMonster.com

yes Allen they are bound to a yes/no field from a table. Thanks, I'll find
a workaround for it.
 
D

Dale Fye

Sheniece,

Just set the option groups default value (form design) or the fields default
value (in table design) to True or False.

HTH
Dale
--
Don''t forget to rate the post if it was helpful!

email address is invalid
Please reply to newsgroup only.
 
A

Allen Browne

Assuming that you do want to be able to store Null, use an Integer field
instead of a yes/no field.

This gives you the 3 states: Yes (-1), No (0), and Null.

An option group does not give the user a way to go back to Null, so you may
need a command button beside the group to set the value to Null.
Alternatively, use a combo.
 
S

sheniece via AccessMonster.com

Allen thanks for the help, I used an integer field instead, and used an
option group check box and it worked like a charm, again thanks for the help.

Allen said:
Assuming that you do want to be able to store Null, use an Integer field
instead of a yes/no field.

This gives you the 3 states: Yes (-1), No (0), and Null.

An option group does not give the user a way to go back to Null, so you may
need a command button beside the group to set the value to Null.
Alternatively, use a combo.
yes Allen they are bound to a yes/no field from a table. Thanks, I'll
find
[quoted text clipped - 15 lines]
 

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

Similar Threads


Top