Combo Box

truebytes

New member
Local time
Today, 13:57
Joined
Apr 29, 2008
Messages
4
Hello friends,

I am very new into the access programme. I have created a combo box with two columns. But when I try to select the values, only one value is coming into the combo box field. How can i select and input both the values which is displaying in the combo box ?

Thanks in advance
yours true
 
Hello friends,

I am very new into the access programme. I have created a combo box with two columns. But when I try to select the values, only one value is coming into the combo box field. How can i select and input both the values which is displaying in the combo box ?

Thanks in advance
yours true
in order to see both values you need to set up the combo box property column widths under format to be 1";1" and set the column count as 2 .As for you second question i don't understand what you are saying
 
a combo box always displays the first column with a non zero width.

There are two ways to overcome this
1) concatenate all your colums in the underlying query (except your PK)
2) use the column() property of the combo box to populate a control for each column you need to view in the after udate event of the combo box.
 
Last edited:
in order to see both values you need to set up the combo box property column widths under format to be 1";1" and set the column count as 2 .As for you second question i don't understand what you are saying


hello friends,

Thanks for the reply.

I am able to view both the columns when i click on the combo box. but after click on the values, only one value is coming into the combo box. Please find below the query.

SELECT qry.columnName, qry.columnlName
FROM qry;
 
hello friends,

Thanks for the reply.

I am able to view both the columns when i click on the combo box. but after click on the values, only one value is coming into the combo box. Please find below the query.

SELECT qry.columnName, qry.columnlName
FROM qry;
From what i know you can store only one value in a combo box
For example if you have a Person id , Person and Gender, and they are related
only one value will be stored when you click on the combo box either Person id,Person, Or Gender
 
From what i know you can store only one value in a combo box
For example if you have a Person id , Person and Gender, and they are related
only one value will be stored when you click on the combo box either Person id,Person, Or Gender

Hi,
Thanks again.
how can we store the other values to the text fields ?

Thanks in advance
true
 
to have the second valua visible on your form
create an unbound text box
on the AfterUpdate event of the combobox put in the code

me.text2 = me.Combo1.column(1)

assuming the unbound text box is called text2 and your combo is called Combo1
 
to have the second valua visible on your form
create an unbound text box
on the AfterUpdate event of the combobox put in the code

me.text2 = me.Combo1.column(1)

assuming the unbound text box is called text2 and your combo is called Combo1

hello friend,

it worked. Thanks very much.

regds
true
 

Users who are viewing this thread

Back
Top Bottom