I have 4 column in datagridview, Item, Qty,Rate,Total. I am creating the dropdown list for the columnItem column from the following sql
Select A.Code, A.Description From kmProduct A Where A.Hidden = 'F'Order ByA.Code
My code is as follows
DataGridViewComboBoxColumn ColProduct = new DataGridViewComboBoxColumn();
ColProduct.DataPropertyName = "Code";
ColProduct.HeaderText = "Description";
kmInvoice objKmInvoice = new kmInvoice();
DataTable t = new DataTable();
t = objKmInvoice.GetProductList();
ColProduct.DataSource = t;
ColProduct.ValueMember = "Code";
ColProduct.DisplayMember = "Description";
dataGridViewInvoice.Columns.Add(ColProduct);
After running the application, it create a new column with the name of Description. How I can create the dropdown to the existing column 'Item' Please any help very appreciate.
Regards
Pol
polachan