Continuous form with dependant combo boxes

oxicottin

Learning by pecking away....
Local time
Yesterday, 19:05
Joined
Jun 26, 2007
Messages
889
I have a continuous form that has a dependent combo box on it. I have the dependent working individually for each row/record BUT the dependent combo box is blank unless it has focus then it shows the saved data so what I did was placed a text box over the data portion of the combo box and set its control source to the same field as the dependent combo box and requeried and it worked great BUT unlike a combo box which would show the name it shows the saved data which is a ID number so I guess my question is how can I show the name and not the data number?

Thanks!
 
for text box. =comboboxName.column(Number of the data column you want to show -1)
Combo boxes number starts at 0 not 1.

Dale
 
for text box. =comboboxName.column(Number of the data column you want to show -1)
Combo boxes number starts at 0 not 1.

Dale

Dale I tried that B4 and it does the same thing, when the column/box has focus then it shows. Any other ideas?

Update:

Could I use a sql for the textbox control source to displa it correctly?

Code:
SELECT tblDelayMachineOutput.Activity, tblDelayActivities.Activity
FROM tblDelayActivities INNER JOIN tblDelayMachineOutput ON tblDelayActivities.ActivityID = tblDelayMachineOutput.Activity;
 
BUT unlike a combo box which would show the name it shows the saved data which is a ID number so I guess my question is how can I show the name and not the data number?

for text box. =comboboxName.column(Number of the data column you want to show -1)

The combo box holds something like, combobox.column(0) = ID: combobox.Column(1) = Text: Combobox.Column(2)= Text.

Unless I don't understand your question.

Dale
 
yes that is correct BUT it wont display it unless it has focus. also, I updated my last question about sql... Mabe that would work?
 
If I am understanding correctly.
Access does not know what to display until you select something from the combo box.
After selecting something in the combo box the data should display correctly but not before.

Dale
 
OK, here is an example. if you click on the combo box arrow it displays the text but if you go to a new record then the cbobox is blank until clicked on again and then it showed the data so what I did was covered the cbobox up with a text box to show the tables data and it works but like I said the tables data is the ID number and not the text.
 

Attachments

Resolved

I got it working.... I used Dlookup and a query. The only thing I dont like is a requery flickers the activity row. Any other thoughts on how to do this would be great! Thanks!
 

Attachments

Users who are viewing this thread

Back
Top Bottom