private void btSaveCategory_Click(object sender, EventArgs e) { if (tbCategory.Text != "") { try { LoaiSanPhamDAO.InsertLoaiSP(tbCategory.Text); DisplayProductTreeView(); DisplayCategory(); } catch (Exception ex) { MessageBox.Show("Insert error, " + ex); } } else { MessageBox.Show("vui lòng nhập ít nhất 2 kí tự"); } }