我很難搞清楚這一點..我想在我的ComboBox
上添加一個"---OTHERS---"
文本,但我的ComboBox
已填充MySQL的:在mysql-populated組合框上添加「--- OTHERS ---」
conDatabase = new MySqlConnection(constring);
MySqlCommand cmdDatabase = new MySqlCommand("select distinct item_type from Company_db.inventory", conDatabase);
try
{
MySqlDataAdapter sda = new MySqlDataAdapter();
sda.SelectCommand = cmdDatabase;
DataSet dbdataset = new DataSet();
sda.Fill(dbdataset);
cbPart.DataSource = dbdataset.Tables[0];
cbPart.DisplayMember = "item_type";
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
它現在的作品!生病發布解決方案 – DOODpls