Exemple #1
0
 //新增用户按钮事件
 private void ButtonAdd_Click(object sender, EventArgs e)
 {
     ClassSqlConnect add = new ClassSqlConnect();
     string addItems;
     addItems = ("USER" + TextUID1.Text.ToString() + "," + textUName1.Text.ToString()
         + "," + TextUPower1.Text.ToString() + "," + TextUP1.Text.ToString() + " ");
     add.Insert(addItems);
     addItems = ("USER");
     DataSet ds = add.Select(addItems);
     this.DataGridView1.DataSource = ds;
     this.DataGridView1.DataMember = "USERS";
     add.Close();
 }
Exemple #2
0
 //创建销售记录按钮事件
 private void button2_Click(object sender, EventArgs e)
 {
     ClassSqlConnect add = new ClassSqlConnect();
     string addItems;
     addItems = ("SALE" + textBox1.Text.ToString() + "," + textBox2.Text.ToString() + "," + textBox3.Text.ToString() + "," + textBox4.Text.ToString() + ","
         + textBox5.Text.ToString() + "," + textBox6.Text.ToString() + "," + textBox7.Text.ToString() +  " ");
     add.Insert(addItems);
     addItems = ("SALE");
     DataSet ds = add.Select(addItems);
     this.dataGridView1.DataSource = ds;
     this.dataGridView1.DataMember = "SALE";
     add.Close();
 }
Exemple #3
0
 //添加出库记录按钮事件
 private void button8_Click(object sender, EventArgs e)
 {
     ClassSqlConnect add = new ClassSqlConnect();
     string addItems;
     addItems = ("OUST" + textBox7.Text.ToString() + "," + textBox8.Text.ToString() + "," + textBox9.Text.ToString()
         + "," + textBox10.Text.ToString() + " ");
     add.Insert(addItems);
     addItems = ("OUST");
     DataSet ds = add.Select(addItems);
     this.dataGridView2.DataSource = ds;
     this.dataGridView2.DataMember = "OUTSTORE";
     add.Close();
 }