If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Default combo box with multiple columns
I have a combo box with multiple columns that I want to set to a default
selection, based on another selection from a combo box on the same form. I tried setting the value of the combo box in the AfterUpdate event of the first combo box, but nothing is happening to the control. Any ideas? |
#2
|
|||
|
|||
Default combo box with multiple columns
Is the value you are attempting to set the second combo box to contained in
the bound column? You can only set a combo box value to what's contained in the bound column. Carl Rapson "Crossh" wrote in message ... I have a combo box with multiple columns that I want to set to a default selection, based on another selection from a combo box on the same form. I tried setting the value of the combo box in the AfterUpdate event of the first combo box, but nothing is happening to the control. Any ideas? |
#3
|
|||
|
|||
Default combo box with multiple columns
Yes, but the Rowsource is a query using multiple tables.
"Carl Rapson" wrote: Is the value you are attempting to set the second combo box to contained in the bound column? You can only set a combo box value to what's contained in the bound column. Carl Rapson "Crossh" wrote in message ... I have a combo box with multiple columns that I want to set to a default selection, based on another selection from a combo box on the same form. I tried setting the value of the combo box in the AfterUpdate event of the first combo box, but nothing is happening to the control. Any ideas? |
#4
|
|||
|
|||
Default combo box with multiple columns
What code are you using? The problem could be in the code.
What are the fields in your query for the combo And are you really trying to set the value or are you trying to set the criteria? If it is already in the first combo, why is it the value in the second comb? We need more information to try to determine what you are doing vs. what you want to do. Ron |
#5
|
|||
|
|||
Default combo box with multiple columns
Sorry for the confusion. I got it to work by putting another button on the
form. I used the same exact code, except the rowsource for the combobox (I wanted to set the default for) was being set based on the selection from the first combobox. I think it may have something to do with trying to do it in an AfterUpdate event rather than OnClick, although it worked ok for a textbox. Thanks for all you help, anyway. "Ron2006" wrote: What code are you using? The problem could be in the code. What are the fields in your query for the combo And are you really trying to set the value or are you trying to set the criteria? If it is already in the first combo, why is it the value in the second comb? We need more information to try to determine what you are doing vs. what you want to do. Ron |
Thread Tools | |
Display Modes | |
|
|