DataGridView添加模版列

DataGridViewComboBoxColumn d=new DataGridViewComboBoxColumn();            d.CellTemplate = new DataGridViewComboBoxCell();            dataGridView1.Columns.Insert(0, d);            d.HeaderText = "性别";            d.Items.Add("男");            d.Items.Add("女"); 

你可能感兴趣的:(datagridview)