Combo on Form?

Read this slowly, and then read it again.:)
"Mr, Mrs etc" are each records of the Titles table. The combo box uses the Titles table for its "Row Source" property.
The combo box has two columns (TitleID which is a number and Title which is text) but only the second is shown when the combo is dropped open because the "Column Widths" property is set to 0cm;0.769cm. "TitleID" is in the column that is set to 0cm and "Title" is in the column that is set to 0.769cm.
The combo box is bound to the "TitleID" field (its Row Source property) in the table that the form is bound to ("tblCustomerDetails").
When a selection is made in the combo box it is the "TitleID" value that is stored in the forms bound table. If you select "Miss" in the combo box for the customer (CustID 1) "Lesley Waaaaaa", save the record nad then open the "tblCustomerDetails" table, you will see that the number stored in the record for TitleID is 3, which is the ID number of "Miss" in the "tblTitleList" table.
OK, will have to read it slowly more than twice! Thank you. Sorry to be a pain! I dont just want to copy and paste stuff or let everyone else do it for me, I want to be able to do it myself at some stage!
Ani:o
 
Hi Rain
Bob's Query for the form should not include the Table tblTitleList So delete that table from the query.
I think you will find that the db I posted uses the "tblCustomerDetails" table as its Record Source. The query called "tblCustomerDetails Query" was in the db posted by Ani.
 
OK, will have to read it slowly more than twice! Thank you. Sorry to be a pain! I dont just want to copy and paste stuff or let everyone else do it for me, I want to be able to do it myself at some stage!
A few of my thoughts:
First: Nobody that wants to learn is a pain.
Second: I'm sure that everybody wants you to be able to do it for yourself once you have learnt.
Third: Until you can do it for yourself, feel free to post as many questions as you need to.
Fourth: When you can do it, try to help someone here who can't.:)
 
A few of my thoughts:
First: Nobody that wants to learn is a pain.
Second: I'm sure that everybody wants you to be able to do it for yourself once you have learnt.
Third: Until you can do it for yourself, feel free to post as many questions as you need to.
Fourth: When you can do it, try to help someone here who can't.:)

Thank you! That makes me feel slightly better though still rather stupid! ;)
I would be happy to help someone else! If I ever get that far.
I still do not understand where the choices for the drop down are put in. Using the wizard.
Ani
 
I still do not understand where the choices for the drop down are put in. Using the wizard.
Ani
If nobody else replies I will try to explain tomorrow.
I have finished watching the England game and I'm going to cry myself to sleep. :rolleyes:
 
If nobody else replies I will try to explain tomorrow.
I have finished watching the England game and I'm going to cry myself to sleep. :rolleyes:

oh dear! I dont watch the football...presume they lost then?
Ani
 
Hi Rain
I think you will find that the db I posted uses the "tblCustomerDetails" table as its Record Source. The query called "tblCustomerDetails Query" was in the db posted by Ani.

Sorry Bob for getting that wrong.
 
...

I still do not understand where the choices for the drop down are put in. Using the wizard.
Ani

The first step of the Combo Box wizard allows you to select the Table or Query that will form the Combo's Row Source this is where the list of options that appear in your Combo Box are drawn from.

attachment.php


To add items to the list all you need to do is add them to the underlying table. This is often done through the Double Click event of the Combo in question.
 

Attachments

  • ComboWiz 1.PNG
    ComboWiz 1.PNG
    50.5 KB · Views: 159
Ani

I finally worked out what your problem is.

You have not normailised properly.

All these items belong in the same Column/Field. They are not separate items requiring separate Fields.

Your table should only have TWO Fields. The ID (AutoNumber) and the Title (Text).

Once you understand this your problems will be 99% solved.

Please note, a Field is the same as a Column.
 
Last edited:
  • Like
Reactions: Ani
Thanks Rain! Makes sense now.
1. I thought that the combo table needed the 'values' in as fields.
2. The column/field thing confused me.
3. Im not exactly sure what 'value' means in ADB speak...I should look up the definitions again I think!
Ani :)
 
The first step of the Combo Box wizard allows you to select the Table or Query that will form the Combo's Row Source this is where the list of options that appear in your Combo Box are drawn from.

attachment.php


To add items to the list all you need to do is add them to the underlying table. This is often done through the Double Click event of the Combo in question.

Double click is an 'event'! LOL Have been looking at some of the titles in the properties list and have no clue yet what most of them mean but Im trying not to get too far ahead of myself! No doubt I will need to use or set some of them at some point.
Ani:D
 

Users who are viewing this thread

Back
Top Bottom