貌似不可以,你都绑定数据了,设定这个cell的值了,怎么再换成ComboBox
?
补充:我试验了一下,拖了个.DataGridView控件,第一列是DataGridViewTextBoxColumn,第二列是DataGridViewComboBoxColumn,然后在Designer.cs里面代码是这样的
private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
private System.Windows.Forms.DataGridViewComboBoxColumn Column2;
this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column2 = new System.Windows.Forms.DataGridViewComboBoxColumn();
//这个是将column1,Column2放进dataGridView
this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Column1,
this.Column2});
// 这个是设置column的属性
// Column1
//
this.Column1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
this.Column1.HeaderText = "Column1";
this.Column1.Name = "Column1";
看了上面的代码。应该是不能实现你的要求的