/// <summary> /// ////////////////// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void button1_Click(object sender, EventArgs e) { if (textBox1.Text.Length > 0) { try { dbsql.AddNewCategory(textBox1.Text); Refersh1(); textBox1.Focus(); } catch (Exception ex) { MessageBox.Show(ex.Message); } } }