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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Combo box formatting 2

Status
Not open for further replies.

jasonsas

Technical User
Oct 2, 2002
63
AU
A user is having a problem with a combo box. She has setup the drop down list to be a SELECT query of 3 fields. When she drops down the list, she can see the 3 fields (venue id, venue name and date), however when she selects one of these values, it only displays the venue id and venue name on the field.

Physically making the combo box longer does not help.

Can someone please help??

Thanks!
 
How are ya jasonsas . . .

The [blue]textbox portion[/blue] of a combobox can only display a single column. That column is determined by the the [blue]first non-zero column[/blue] of the [purple]Column Widths[/blue] property.

[blue]0";1";1"[/blue] displays column1 & column2 in the dropdown (column index starts at zero), and column1 is seen in the textbox portion upon selection.

[blue]0.5";1";1"[/blue] displays column0, column1, and column2 in the dropdown, and column0 is seen in the textbox portion upon selection.

Calvin.gif
See Ya! . . . . . .
 
Hi Aceman,

I think you have answered my question. Just to confirm, when I actually drop down the menu I can change what is seen by changing the "column width" variables.

BUT, only ONE column will ever be able to be seen on the actual display?

Thanks,
Jason
 
jasonsas . . .

You got it! . . . just refer to the actual display as the texbox portion of the combobox.

Calvin.gif
See Ya! . . . . . .
 
OK, I now have another question. Because we can only display one field at a time in the actual display, we would like to setup another "field" in the form to automatically populate the date based on the variable they choose in the combo box.

does this make sense??
 
Set the texbox control source property to:
=ComboName.Column(2)

(Numbering starts at 0)
 
. . . or, in the [blue]AfterUpdate[/blue] event of the combobox:
Code:
[blue]   Me![purple][b]TextboxName[/b][/purple] = Me![purple][b]ComboboxName[/b][/purple].Column(2)[/blue]

Calvin.gif
See Ya! . . . . . .
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top