Hello,
I have the following:
- tblProductList - table with prod1, prod2 and prod3 fields
- frmProductList - form, made automatically when I made the subform
- frmProductSearch - main form
- sfProductList - subform, takes values from the table
- cBx1, cBx2 and cBx3 - combo boxes that act as filter selection for the subform
Made in the main form header 3 combo boxes, each to act as a filter for the 3 fields in the subform in the same page.
- i have managed to make the filters to work together, so i can narrow down my search - a relative long repetitive vba code using NZ function
- i have manage to make cBx1, cBx2 and cBx3 to take all the values but no duplicates from prod1, prod2 and prod3 using SQL view on the code of the combo box and using
SELECT DISTINCT tblProductList.prod1
FROM tblProductList
ORDER BY tblProductList.prod1
- i can't manage to make the combo boxes take the values from the remaining values in the subform, so that after i am using 1 of the filters, the other 2 to display the remaining values that can be usable ( shown in the subform ) insted of all of the available values from the table.
I tried to change the source but haven't managed and also i haven't managed to make the filtering happen in a query and the subform to take the remaining values from there or something...
Also it will be great, instead of showing every value from the table in the subform, before i start to filter, the subform to be blank and values to appear after the filtering starts.
Any help with my quest ?
I have the following:
- tblProductList - table with prod1, prod2 and prod3 fields
- frmProductList - form, made automatically when I made the subform
- frmProductSearch - main form
- sfProductList - subform, takes values from the table
- cBx1, cBx2 and cBx3 - combo boxes that act as filter selection for the subform
Made in the main form header 3 combo boxes, each to act as a filter for the 3 fields in the subform in the same page.
- i have managed to make the filters to work together, so i can narrow down my search - a relative long repetitive vba code using NZ function
- i have manage to make cBx1, cBx2 and cBx3 to take all the values but no duplicates from prod1, prod2 and prod3 using SQL view on the code of the combo box and using
SELECT DISTINCT tblProductList.prod1
FROM tblProductList
ORDER BY tblProductList.prod1
- i can't manage to make the combo boxes take the values from the remaining values in the subform, so that after i am using 1 of the filters, the other 2 to display the remaining values that can be usable ( shown in the subform ) insted of all of the available values from the table.
I tried to change the source but haven't managed and also i haven't managed to make the filtering happen in a query and the subform to take the remaining values from there or something...
Also it will be great, instead of showing every value from the table in the subform, before i start to filter, the subform to be blank and values to appear after the filtering starts.
Any help with my quest ?