Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

setting value in combo box

Status
Not open for further replies.

stuckagain1

Technical User
May 3, 2004
86
US
i have a form that has a creator field, a creator id field and a donor field. the creator field refers to name on a previously opened form as does the creator id. the donor field defaults to the creator field.

i want to change the donor field to a combo box so that the user can look up names in a table when the donor name does not match the creator name. i believe the bound column needs to be the id field in the lookup table.

most times, the donor will match the creator, so i need the default value for the combo box to be equal to the creator's name/id.........how do i do this? i don't think i can just say the default value is equal to the id field that is on the form in the combo box properties...that doesn't seem to work.......

how can i do this?
thanks!
 
You should have a donor table, which will contain a creatorID FK. You should then have a creator table which will contain a CreatorID & Creator field.

You then create a combo, bound to Donor.CreatorID, but with its rowsource set to 'SELECT CreatorID, Creator FROM Creator'.

You can then add a donorID with its default value = the CreatorID combo. This should then work...

James Goodman MCSE, MCDBA
 
Thanks, but the donor and creator table really need to be one because a donor is usually also a creator, as is the creator a donor. i don't want to keep addresses in two places, and the reason i need this is to be able to send thank you letters to the donor, which may or may not be the creator. (sometimes the item that is donated has multiple creators (such as CD with different artists), but only one of them donated the item.

confusing?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top