# Thread: COMBO BOX HELP! (ACCESS 2000)

1. ## COMBO BOX HELP! (ACCESS 2000)

I would like some help on the following:
I have a combo box on a form that; after update, I would like it to place a certain value (either .25 or 1) in a text box field on the same form. This value must be stored in the table that the form is based on.

2. ## Re: COMBO BOX HELP! (ACCESS 2000)

I'm not clear on the logic that makes this decision, but On the AfterUpdate Event of the ComboBox, place an If statement that reads something like:

If Me!ComboBoxName = choice1(the value that determines a .25 should be placed) Then
Me!TextboxName = .25
Else If Me!ComboBoxName = choice2 (the value that determines a 1should be placed) Then
Me!TextboxName = 1
.. other choices continue here
End If

If your TextBox is bound to the field in the table, the value will be stored.
If there are numerous choices, you may want to consider a Case statement instead.
Post back with a few more details if this isn't helpful enough.

3. ## Re: COMBO BOX HELP! (ACCESS 2000)

Storing a value in a field that is dependent on the value of a field in the same table is generally not a good idea. It in fact violates the Rules of Normalization. This value you want to save should be in the table behind the combo box. For example, let's say the combo box has values of Large, Medium, and Small, and you want to assign a weight of 3, 2, and 1 respectively. You should have a Colors table that has 2 fields in it: Color and Weight. You can then join this colors table with your main table to get the weight of any color when you need it. Additionally, if you decide to change the weights (to 5,3, and 1), you don't have to change any of the values in your main table.

4. ## Re: COMBO BOX HELP! (ACCESS 2000)

Hey Thomas
Your suggestion worked GREAT! Thank you for the quick response and timely advice

5. ## Re: COMBO BOX HELP! (ACCESS 2000)

It did not occur to me that you might be trying to save a value in a table that was the same table referenced by your ComboBox. If this is the case, please refer to Mark's comment and post back. We can help you find a way to do this that doesn't break normalization rules.

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•