private void button5_Click(object sender, EventArgs e) { FoodCategoryDAO fcDAO = new FoodCategoryDAO(); if (fcDAO.addFoodCategory(textBox2.Text)) { MessageBox.Show("Dữ liệu được thêm thành công", "Thêm thành công", MessageBoxButtons.OK, MessageBoxIcon.Information); dataGridView1.DataSource = fcDAO.loadFoodCategories(); } else { MessageBox.Show("Dữ liệu không được thêm", "Thêm thất bại", MessageBoxButtons.OK, MessageBoxIcon.Error); } }