How can i remove duplicate item from combobox with datasource?
-
Dear all.
Manufacture Model No Length Width height
Manufacture 1 MD-01 200 300 100
Manufacture 1 MD-02 300 400 100
Manufacture 1 MD-03 400 300 150
Manufacture 2 MAD-01 200 450 100
Manufacture 2 MAD-02 250 400 100
Manufacture 3 MDI-01 300 300 100
Manufacture 4 MOv-01 350 300 100
I would like to create 2 combobox - 1) Manufacture 2 ) model No Manufacture should display for above example Manufacture 1,Manufacture 2,Manufacture 3, Manufacture 4 when particular manufacture selected for example Manufacture 2 -> combox should display only MAD-01 & MAD 02. Based on both selection text box must me loaded with length, width , height. i tried sample code & try to assign the combox with database value. I found duplicate list of column. Like for combobox1 accumulate Manufacture 1 Manufacture 1 Manufacture 1 Manufacture 2 Manufacture 2 Manufacture 3 Manufacture 4 Is there any example program available to do this. How can do this. can some one give example program for this
-
Dear all.
Manufacture Model No Length Width height
Manufacture 1 MD-01 200 300 100
Manufacture 1 MD-02 300 400 100
Manufacture 1 MD-03 400 300 150
Manufacture 2 MAD-01 200 450 100
Manufacture 2 MAD-02 250 400 100
Manufacture 3 MDI-01 300 300 100
Manufacture 4 MOv-01 350 300 100
I would like to create 2 combobox - 1) Manufacture 2 ) model No Manufacture should display for above example Manufacture 1,Manufacture 2,Manufacture 3, Manufacture 4 when particular manufacture selected for example Manufacture 2 -> combox should display only MAD-01 & MAD 02. Based on both selection text box must me loaded with length, width , height. i tried sample code & try to assign the combox with database value. I found duplicate list of column. Like for combobox1 accumulate Manufacture 1 Manufacture 1 Manufacture 1 Manufacture 2 Manufacture 2 Manufacture 3 Manufacture 4 Is there any example program available to do this. How can do this. can some one give example program for this
Also in the VB-forum; please don't crosspost. Instead of removing the duplicates, I'd recommend to have a
DISTINCT
list of the names to load in the combo. Google for "SELECT DISTINCT" to get examples.Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^][](X-Clacks-Overhead: GNU Terry Pratchett)