Combo Box

M

Michael

Hi Folks - I have combo box that displays an autonumber primary key and a
status field such as:

1 Active
2 Inactive
3 On Hold
etc.

I want the dropdown to display the status items, but I want the underlying
table to store the ID field. I can get the dropdown to display the status
items AND store the ID, but once a dropdown item is selected, the ID is
displayed. I'd like the status item to be displayed after the selection, but
have the ID stored instead of the status item.

Make sense? Thanks,

Michael
 
A

Allen Browne

Set these properties for your combo:
Column Count: 2
Column Widths: 0
Bound Column: 1
RowSource: SELECT StatusID, StatusName FROM tblStatus ORDER BY
StatusName;

Hopefully you can adjust the RowSource query to your actual field names, or
get Access to build this for you. The important thing is that the ID is in
the first column (which is the bound column but zero-width, so the 2nd
column is what you see.)
 

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

Top