Hi!
Access2010 with SQl-server 2008R2:
on a form there are three comboboxes which are dependant in sequence.
Entering data int the first one, gives the rowsource for the second one.
Entering data int the second one, gives the rowsource for the third one.
in the rowsource of the combobox is the same sql string but no filter in it, so that in a finished record I can see the "readable" values and not the ID in column(0) which is not visible.
whenever I change the selection in combobox2 to alter date in combobox3 i get the correct selection for combobox3. but scrolling to other records with differnt content in combobox2 does not show any content in combobox3 of the records, allthough the data have not been changed.
When I enter combobox3 of any other record different to the one I changed, it seems that the filter of the former changed record is still there, although the
For example
combo1: Region, values 1,2,3
combo2: Salesman, values 1 in R 1, 2 in R 1, 3 in R 3
combo3: Customers, values 1 Salesman 1, 2 S 1, 3 S 3
Rowsource combo1: SElect * from Region
Rowsource combo2: Select * from Salesman
Rowsource combo3: Select * from Customers
AfterUpdate_Region
Me.Salesman.rowsource="Select * From Salesman where Region=" & Me.Region.column(0)
AfterUpdate_Salesman
Me.Customers.rowsource="Select * From Customers where Salesman =" & Me.Salesman .column(0)
Scrolling to another record should "cancel" the filtered rowsources and take the "general" rowsource from above.
But the field customer stays empty, although the value is in the table.
When I enter the combo the selection of the former record is visible!
Now, I do not know, if it only a problem of displaying the record or that the rowsource is not "reset" by scrolling the record.
I tried also to "reset" the rowsourced in the Form_Current Event, which works correct now, I can see in the empty combos the correct selection, which means ALL Customers, but it remains the problem of displaying the value of the combobox, which should be column(1) of the rowsource.
The users think that there are no date in the combos and tries to fill in again.
there is not much difference if the rowsource is an sql-string from the linked tables, a view or a stored procedure from the server.
sometime you can see the date of column(1), sometime you don't.
Any idea how to change this?
Thanks
Michael
Access2010 with SQl-server 2008R2:
on a form there are three comboboxes which are dependant in sequence.
Entering data int the first one, gives the rowsource for the second one.
Entering data int the second one, gives the rowsource for the third one.
in the rowsource of the combobox is the same sql string but no filter in it, so that in a finished record I can see the "readable" values and not the ID in column(0) which is not visible.
whenever I change the selection in combobox2 to alter date in combobox3 i get the correct selection for combobox3. but scrolling to other records with differnt content in combobox2 does not show any content in combobox3 of the records, allthough the data have not been changed.
When I enter combobox3 of any other record different to the one I changed, it seems that the filter of the former changed record is still there, although the
For example
combo1: Region, values 1,2,3
combo2: Salesman, values 1 in R 1, 2 in R 1, 3 in R 3
combo3: Customers, values 1 Salesman 1, 2 S 1, 3 S 3
Rowsource combo1: SElect * from Region
Rowsource combo2: Select * from Salesman
Rowsource combo3: Select * from Customers
AfterUpdate_Region
Me.Salesman.rowsource="Select * From Salesman where Region=" & Me.Region.column(0)
AfterUpdate_Salesman
Me.Customers.rowsource="Select * From Customers where Salesman =" & Me.Salesman .column(0)
Scrolling to another record should "cancel" the filtered rowsources and take the "general" rowsource from above.
But the field customer stays empty, although the value is in the table.
When I enter the combo the selection of the former record is visible!
Now, I do not know, if it only a problem of displaying the record or that the rowsource is not "reset" by scrolling the record.
I tried also to "reset" the rowsourced in the Form_Current Event, which works correct now, I can see in the empty combos the correct selection, which means ALL Customers, but it remains the problem of displaying the value of the combobox, which should be column(1) of the rowsource.
The users think that there are no date in the combos and tries to fill in again.
there is not much difference if the rowsource is an sql-string from the linked tables, a view or a stored procedure from the server.
sometime you can see the date of column(1), sometime you don't.
Any idea how to change this?
Thanks
Michael