Option Group Viewing Selection

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

Guest

I have option groups on a form for which I use Case Event Code in the after update area to convert the selection from the numbers assigned to text which works fine except for one thing.

When I want to allow data to be edited that was previously entered by opening the form in edit mode the selections made do not show up on the form even though the data is in the table converted correctly.

Any way to make the selections visible?
 
Hi Brian,

I can't understand what you're trying to communicate. Please take another
cut at describing - in meaningful detail- what you are trying to achieve,
how you've gone about it so far and what's actually happening.

HTH
--
-Larry-
--

bdehning said:
I have option groups on a form for which I use Case Event Code in the
after update area to convert the selection from the numbers assigned to text
which works fine except for one thing.
When I want to allow data to be edited that was previously entered by
opening the form in edit mode the selections made do not show up on the form
even though the data is in the table converted correctly.
 
Larry,

Option groups are set up such that when you make a selection from shown items on a form, a value is assigned that the user can determine but must be numerical. Using the example from help they show Speedy, United and Federal. Access assigns numbers to the selection so in the table if Speedy is selected it says 1 and not Speedy.

The problem is that I want text and not numbers to appear and like the look of option groups.

I created tables for each option group with the available selections. I then place the following for example in the After Update area of the Option Group on my form. When Excellent is selected the table correctly displays Excellent.

Private Sub Frame58_AfterUpdate()
Select Case Frame58.Value
Case 1
Evaluation.Value = "Excellent"
Case 2
Evaluation.Value = "Good"
Case 3
Evaluation.Value = "Average"
Case 4
Evaluation.Value = "Below Average"
Case 5
Evaluation.Value = "Poor"
End Select

The problem is that when I go back to edit these fields on the form or bring up the form in edit mode, the check boxes selection in the option group do not show as all
are grayed out.

I would like the selections to be visible. Do I need to do something different when I convert the data to text to make this happen?--
Brian

You are miss-using the Option Group.
The value of an Option Group is a Number.
A table field, bound to the Option Group must be a Number datatype.

If you wish to display an Option Group number's associated text in a
form or a report, you can do so, using the same Select Case you are
now currently using (or the Choose() function), but the value stored
in the table must be a number.

There is really no need to store the text equivalent in a table.

You'll need to go back and re-convert all your text data into number
data in a Number (Integer) datatype field. An Update query could do it
for you.

Then on the form, use the Option Group to enter or change the value.

Then, on the form, if you wish to display the text "Good" instead of
the radio buttons, use one unbound text control with it's control
source set to:
=Choose([FieldName],"Excellent","Good","Average","Below
Average","Poor")

The Choose function can also be used in a Report.
 
-- I am trying the record source

=Choose([Evaluation],"Excellent","Good","Average","Below Average","Poor")
with having changed the table data type. The text box with the above record source on the form says error.
Brian


fredg said:
Larry,

Option groups are set up such that when you make a selection from shown items on a form, a value is assigned that the user can determine but must be numerical. Using the example from help they show Speedy, United and Federal. Access assigns numbers to the selection so in the table if Speedy is selected it says 1 and not Speedy.

The problem is that I want text and not numbers to appear and like the look of option groups.

I created tables for each option group with the available selections. I then place the following for example in the After Update area of the Option Group on my form. When Excellent is selected the table correctly displays Excellent.

Private Sub Frame58_AfterUpdate()
Select Case Frame58.Value
Case 1
Evaluation.Value = "Excellent"
Case 2
Evaluation.Value = "Good"
Case 3
Evaluation.Value = "Average"
Case 4
Evaluation.Value = "Below Average"
Case 5
Evaluation.Value = "Poor"
End Select

The problem is that when I go back to edit these fields on the form or bring up the form in edit mode, the check boxes selection in the option group do not show as all
are grayed out.

I would like the selections to be visible. Do I need to do something different when I convert the data to text to make this happen?--
Brian

You are miss-using the Option Group.
The value of an Option Group is a Number.
A table field, bound to the Option Group must be a Number datatype.

If you wish to display an Option Group number's associated text in a
form or a report, you can do so, using the same Select Case you are
now currently using (or the Choose() function), but the value stored
in the table must be a number.

There is really no need to store the text equivalent in a table.

You'll need to go back and re-convert all your text data into number
data in a Number (Integer) datatype field. An Update query could do it
for you.

Then on the form, use the Option Group to enter or change the value.

Then, on the form, if you wish to display the text "Good" instead of
the radio buttons, use one unbound text control with it's control
source set to:
=Choose([FieldName],"Excellent","Good","Average","Below
Average","Poor")

The Choose function can also be used in a Report.
 
-- I am trying the record source

=Choose([Evaluation],"Excellent","Good","Average","Below Average","Poor")
with having changed the table data type. The text box with the above record source on the form says error.
Brian

fredg said:
Larry,

Option groups are set up such that when you make a selection from shown items on a form, a value is assigned that the user can determine but must be numerical. Using the example from help they show Speedy, United and Federal. Access assigns numbers to the selection so in the table if Speedy is selected it says 1 and not Speedy.

The problem is that I want text and not numbers to appear and like the look of option groups.

I created tables for each option group with the available selections. I then place the following for example in the After Update area of the Option Group on my form. When Excellent is selected the table correctly displays Excellent.

Private Sub Frame58_AfterUpdate()
Select Case Frame58.Value
Case 1
Evaluation.Value = "Excellent"
Case 2
Evaluation.Value = "Good"
Case 3
Evaluation.Value = "Average"
Case 4
Evaluation.Value = "Below Average"
Case 5
Evaluation.Value = "Poor"
End Select

The problem is that when I go back to edit these fields on the form or bring up the form in edit mode, the check boxes selection in the option group do not show as all
are grayed out.

I would like the selections to be visible. Do I need to do something different when I convert the data to text to make this happen?--
Brian

:

Hi Brian,

I can't understand what you're trying to communicate. Please take another
cut at describing - in meaningful detail- what you are trying to achieve,
how you've gone about it so far and what's actually happening.

HTH
--
-Larry-
--

I have option groups on a form for which I use Case Event Code in the
after update area to convert the selection from the numbers assigned to text
which works fine except for one thing.

When I want to allow data to be edited that was previously entered by
opening the form in edit mode the selections made do not show up on the form
even though the data is in the table converted correctly.

Any way to make the selections visible?

You are miss-using the Option Group.
The value of an Option Group is a Number.
A table field, bound to the Option Group must be a Number datatype.

If you wish to display an Option Group number's associated text in a
form or a report, you can do so, using the same Select Case you are
now currently using (or the Choose() function), but the value stored
in the table must be a number.

There is really no need to store the text equivalent in a table.

You'll need to go back and re-convert all your text data into number
data in a Number (Integer) datatype field. An Update query could do it
for you.

Then on the form, use the Option Group to enter or change the value.

Then, on the form, if you wish to display the text "Good" instead of
the radio buttons, use one unbound text control with it's control
source set to:
=Choose([FieldName],"Excellent","Good","Average","Below
Average","Poor")

The Choose function can also be used in a Report.

The Field [Evaluation], in the Table, is now a number datatype, with
values of 1,2,3,4,5.
The Choose function is placed in an UNBOUND Control's Control Source
(not a Record Source).

1) If the Name of the Control is "Evaluation" you will get an error.
change the Control's Name to something else.

2) Perhaps you are getting a record that is not yet filled in.
Change the control source to:
=IIf([Evaluation] >0, Choose([Evaluation], "Excellent",
"Good","Average","Below Average","Poor"),"N/A")
 
Thanks Fred. Changing the name did the trick.

Why won't Microsoft develop option groups to display text in tables rather than numbers like other databases?
--
Brian


fredg said:
-- I am trying the record source

=Choose([Evaluation],"Excellent","Good","Average","Below Average","Poor")
with having changed the table data type. The text box with the above record source on the form says error.
Brian

fredg said:
On Fri, 2 Jul 2004 07:21:05 -0700, bdehning wrote:

Larry,

Option groups are set up such that when you make a selection from shown items on a form, a value is assigned that the user can determine but must be numerical. Using the example from help they show Speedy, United and Federal. Access assigns numbers to the selection so in the table if Speedy is selected it says 1 and not Speedy.

The problem is that I want text and not numbers to appear and like the look of option groups.

I created tables for each option group with the available selections. I then place the following for example in the After Update area of the Option Group on my form. When Excellent is selected the table correctly displays Excellent.

Private Sub Frame58_AfterUpdate()
Select Case Frame58.Value
Case 1
Evaluation.Value = "Excellent"
Case 2
Evaluation.Value = "Good"
Case 3
Evaluation.Value = "Average"
Case 4
Evaluation.Value = "Below Average"
Case 5
Evaluation.Value = "Poor"
End Select

The problem is that when I go back to edit these fields on the form or bring up the form in edit mode, the check boxes selection in the option group do not show as all
are grayed out.

I would like the selections to be visible. Do I need to do something different when I convert the data to text to make this happen?--
Brian

:

Hi Brian,

I can't understand what you're trying to communicate. Please take another
cut at describing - in meaningful detail- what you are trying to achieve,
how you've gone about it so far and what's actually happening.

HTH
--
-Larry-
--

I have option groups on a form for which I use Case Event Code in the
after update area to convert the selection from the numbers assigned to text
which works fine except for one thing.

When I want to allow data to be edited that was previously entered by
opening the form in edit mode the selections made do not show up on the form
even though the data is in the table converted correctly.

Any way to make the selections visible?
--
Brian



You are miss-using the Option Group.
The value of an Option Group is a Number.
A table field, bound to the Option Group must be a Number datatype.

If you wish to display an Option Group number's associated text in a
form or a report, you can do so, using the same Select Case you are
now currently using (or the Choose() function), but the value stored
in the table must be a number.

There is really no need to store the text equivalent in a table.

You'll need to go back and re-convert all your text data into number
data in a Number (Integer) datatype field. An Update query could do it
for you.

Then on the form, use the Option Group to enter or change the value.

Then, on the form, if you wish to display the text "Good" instead of
the radio buttons, use one unbound text control with it's control
source set to:
=Choose([FieldName],"Excellent","Good","Average","Below
Average","Poor")

The Choose function can also be used in a Report.

The Field [Evaluation], in the Table, is now a number datatype, with
values of 1,2,3,4,5.
The Choose function is placed in an UNBOUND Control's Control Source
(not a Record Source).

1) If the Name of the Control is "Evaluation" you will get an error.
change the Control's Name to something else.

2) Perhaps you are getting a record that is not yet filled in.
Change the control source to:
=IIf([Evaluation] >0, Choose([Evaluation], "Excellent",
"Good","Average","Below Average","Poor"),"N/A")
 
Hi Brian,

If you were provided the Solutions database with your Access/Office
materials I commend you to it. I'm pretty sure that everyone is given a
copy of the Northwinds database in their version. In the case of Solutions
you get directed examples of techniques (maybe that's just the developer
tools). In Northwind there are lots of examples but you have to go into
design mode and chase and analyze the code yourself. In addition, there are
books about getting going with Access. One good beginning level book is
"Microsoft Access [yourversion] Step by Step" from Microsoft Press. You may
be well beyond that level and are aware that there are books that are useful
at just about any level of expertise.

I suggest that, before you go looking for help in getting something in
Access to work in some way inconsistent with the tools given, you first try
to achieve your objectives by following working examples and only then
modify the working models in the direction you're trying to go. If things
break during that process you'll quickly understand what you did, and soon
thereafter, why it broke.

As to the feature list in Access, everyone has something that they'd like to
see done better (or differently). You might do a google search of the
Access groups on "Wish List" and find a contact point in Microsoft to send
your suggestion. They don't promise response nor action but don't despair.
As other developers have developed solutions to the things that Microsoft
couldn't be bothered with, Lo and Behold! MS managed to incorporate their
solutions into later versions.

--
-Larry-
--

bdehning said:
Thanks Fred. Changing the name did the trick.

Why won't Microsoft develop option groups to display text in tables rather
than numbers like other databases?
--
Brian


fredg said:
-- I am trying the record source

=Choose([Evaluation],"Excellent","Good","Average","Below Average","Poor")
with having changed the table data type. The text box with the above record source on the form says error.
Brian

:

On Fri, 2 Jul 2004 07:21:05 -0700, bdehning wrote:

Larry,

Option groups are set up such that when you make a selection from
shown items on a form, a value is assigned that the user can determine but
must be numerical. Using the example from help they show Speedy, United and
Federal. Access assigns numbers to the selection so in the table if Speedy
is selected it says 1 and not Speedy.selections. I then place the following for example in the After Update area
of the Option Group on my form. When Excellent is selected the table
correctly displays Excellent.or bring up the form in edit mode, the check boxes selection in the option
group do not show as all
are grayed out.

I would like the selections to be visible. Do I need to do something different when I convert the data to text to make this happen?--
Brian

:

Hi Brian,

I can't understand what you're trying to communicate. Please take another
cut at describing - in meaningful detail- what you are trying to achieve,
how you've gone about it so far and what's actually happening.

HTH
--
-Larry-
--

I have option groups on a form for which I use Case Event Code in the
after update area to convert the selection from the numbers assigned to text
which works fine except for one thing.

When I want to allow data to be edited that was previously entered by
opening the form in edit mode the selections made do not show up on the form
even though the data is in the table converted correctly.

Any way to make the selections visible?
--
Brian



You are miss-using the Option Group.
The value of an Option Group is a Number.
A table field, bound to the Option Group must be a Number datatype.

If you wish to display an Option Group number's associated text in a
form or a report, you can do so, using the same Select Case you are
now currently using (or the Choose() function), but the value stored
in the table must be a number.

There is really no need to store the text equivalent in a table.

You'll need to go back and re-convert all your text data into number
data in a Number (Integer) datatype field. An Update query could do it
for you.

Then on the form, use the Option Group to enter or change the value.

Then, on the form, if you wish to display the text "Good" instead of
the radio buttons, use one unbound text control with it's control
source set to:
=Choose([FieldName],"Excellent","Good","Average","Below
Average","Poor")

The Choose function can also be used in a Report.

The Field [Evaluation], in the Table, is now a number datatype, with
values of 1,2,3,4,5.
The Choose function is placed in an UNBOUND Control's Control Source
(not a Record Source).

1) If the Name of the Control is "Evaluation" you will get an error.
change the Control's Name to something else.

2) Perhaps you are getting a record that is not yet filled in.
Change the control source to:
=IIf([Evaluation] >0, Choose([Evaluation], "Excellent",
"Good","Average","Below Average","Poor"),"N/A")
 
Back
Top