Option Group Values

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am currently working with a form in which I am required to input specific codes for answers. In the table and in most of the form I am able to have those codes entered in without a problem because the codes I need entered are numeric codes. But, in the status question, I need a letter entered..."I" for Insert, "U" for Update, and "D" for delete. I've tried various ways of doing option groups, with and without the wizard, and even without the wizard it enters a 1 for Insert, a 2 for Update, and a 3 for Delete without me telling it to. It won't let me set it for the values to be alpha rather than numeric. Also, when I try to create check boxes without an option group...when I open the form, I'm not allowed to select just 1 item if I create it as a check box. It checks all of the items or none of the items, which I can't fixed and has forced me to do the rest of the form as option groups.
Any help on solving my problem would be greatly appreciated...I'm completely stuck and I've tried everything I know how to do. If it is in the coding, then I would need help with that, because I don't understand much of Access coding or where to put it...I haven't worked with it much

To clarify I do have the table set to input the alpha values if I were to input the information directly into the table

Thanks agai
Christin
 
Personally, I would use a Numeric Field of type Byte (allowing 256 options)
in the Table and then use a Table "tlkpAction" with 2 Fields:

* ActionID: Byte PrimaryKey
* ActionDesc: Text that describes the Action.

to translate from a numeric code to the action. Sample data:

ActionID ActionDesc
1 Insert ...
2 Update ...
....

This way, you can simply bind the OptionGroup directly to the Byte Field in
your existing Table. When you want to display the Action Text, you can use
the Table "tlkpAction".

You didn't mention but my guess is that you are using a Form in Continuous
Form View and in that case any unbound Control will have the same value for
all Rows since what you see is many instances of the same Control and the
many instances of the unbound Control have the same value. That's why you
have the problem " ... I'm not allowed to select just 1 item if I create it
as a check box. It checks all of the items or none of the items, ...".

There are work-arounds so that you can retain I, A, ... which involves a
"Translation" Table like the Table "tlkpAction" I mentioned above.

--
HTH
Van T. Dinh
MVP (Access)



Christina said:
I am currently working with a form in which I am required to input
specific codes for answers. In the table and in most of the form I am able
to have those codes entered in without a problem because the codes I need
entered are numeric codes. But, in the status question, I need a letter
entered..."I" for Insert, "U" for Update, and "D" for delete. I've tried
various ways of doing option groups, with and without the wizard, and even
without the wizard it enters a 1 for Insert, a 2 for Update, and a 3 for
Delete without me telling it to. It won't let me set it for the values to
be alpha rather than numeric. Also, when I try to create check boxes
without an option group...when I open the form, I'm not allowed to select
just 1 item if I create it as a check box. It checks all of the items or
none of the items, which I can't fixed and has forced me to do the rest of
the form as option groups.
Any help on solving my problem would be greatly appreciated...I'm
completely stuck and I've tried everything I know how to do. If it is in
the coding, then I would need help with that, because I don't understand
much of Access coding or where to put it...I haven't worked with it much.
To clarify I do have the table set to input the alpha values if I were to
input the information directly into the table.
 
Back
Top