📄 系统维护.cs
字号:
this.sqlSelectCommand2 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand2 = new System.Data.SqlClient.SqlCommand();
this.sqlDataAdapter3 = new System.Data.SqlClient.SqlDataAdapter();
this.sqlDeleteCommand3 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand3 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand3 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand3 = new System.Data.SqlClient.SqlCommand();
this.sqlDataAdapter4 = new System.Data.SqlClient.SqlDataAdapter();
this.sqlDeleteCommand4 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand4 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand4 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand4 = new System.Data.SqlClient.SqlCommand();
this.sqlDataAdapter5 = new System.Data.SqlClient.SqlDataAdapter();
this.sqlDeleteCommand5 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand5 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand5 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand5 = new System.Data.SqlClient.SqlCommand();
this.sqlDataAdapter6 = new System.Data.SqlClient.SqlDataAdapter();
this.sqlDeleteCommand6 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand6 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand6 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand6 = new System.Data.SqlClient.SqlCommand();
this.sqlDataAdapter7 = new System.Data.SqlClient.SqlDataAdapter();
this.sqlDeleteCommand7 = new System.Data.SqlClient.SqlCommand();
this.sqlInsertCommand7 = new System.Data.SqlClient.SqlCommand();
this.sqlSelectCommand7 = new System.Data.SqlClient.SqlCommand();
this.sqlUpdateCommand7 = new System.Data.SqlClient.SqlCommand();
this.groupBox1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dataSet1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dataTable1)).BeginInit();
this.tabControl1.SuspendLayout();
this.tabPage1.SuspendLayout();
this.tabPage2.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid2)).BeginInit();
this.tabPage3.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid3)).BeginInit();
this.tabPage4.SuspendLayout();
this.groupBox5.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid6)).BeginInit();
this.groupBox4.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid5)).BeginInit();
this.groupBox3.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dataGrid4)).BeginInit();
this.groupBox2.SuspendLayout();
this.SuspendLayout();
//
// groupBox1
//
this.groupBox1.Controls.Add(this.radioButton2);
this.groupBox1.Controls.Add(this.radioButton1);
this.groupBox1.Controls.Add(this.button1);
this.groupBox1.Controls.Add(this.textBox2);
this.groupBox1.Controls.Add(this.textBox1);
this.groupBox1.Font = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.groupBox1.Location = new System.Drawing.Point(24, 16);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(600, 120);
this.groupBox1.TabIndex = 0;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "检索条件";
this.groupBox1.Enter += new System.EventHandler(this.groupBox1_Enter);
//
// radioButton2
//
this.radioButton2.Checked = true;
this.radioButton2.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.radioButton2.Location = new System.Drawing.Point(40, 72);
this.radioButton2.Name = "radioButton2";
this.radioButton2.Size = new System.Drawing.Size(72, 24);
this.radioButton2.TabIndex = 6;
this.radioButton2.TabStop = true;
this.radioButton2.Text = "姓名";
this.radioButton2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.radioButton2.CheckedChanged += new System.EventHandler(this.radioButton2_CheckedChanged);
//
// radioButton1
//
this.radioButton1.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.radioButton1.Location = new System.Drawing.Point(40, 32);
this.radioButton1.Name = "radioButton1";
this.radioButton1.Size = new System.Drawing.Size(80, 24);
this.radioButton1.TabIndex = 5;
this.radioButton1.Text = "条形码";
this.radioButton1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
//
// button1
//
this.button1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.button1.Location = new System.Drawing.Point(400, 88);
this.button1.Name = "button1";
this.button1.TabIndex = 4;
this.button1.Text = "查询";
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// textBox2
//
this.textBox2.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.textBox2.Location = new System.Drawing.Point(136, 72);
this.textBox2.Name = "textBox2";
this.textBox2.Size = new System.Drawing.Size(112, 26);
this.textBox2.TabIndex = 3;
this.textBox2.Text = "";
//
// textBox1
//
this.textBox1.Enabled = false;
this.textBox1.Font = new System.Drawing.Font("宋体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.textBox1.Location = new System.Drawing.Point(136, 24);
this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(336, 26);
this.textBox1.TabIndex = 1;
this.textBox1.Text = "";
this.textBox1.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.textBox1_KeyPress);
//
// dataGrid1
//
this.dataGrid1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.dataGrid1.CaptionFont = new System.Drawing.Font("宋体", 10.5F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134)));
this.dataGrid1.CaptionText = "账户表";
this.dataGrid1.DataMember = "";
this.dataGrid1.HeaderForeColor = System.Drawing.SystemColors.ControlText;
this.dataGrid1.Location = new System.Drawing.Point(24, 152);
this.dataGrid1.Name = "dataGrid1";
this.dataGrid1.Size = new System.Drawing.Size(600, 168);
this.dataGrid1.TabIndex = 1;
//
// sqlConnection1
//
this.sqlConnection1.ConnectionString = "workstation id=XU;packet size=4096;integrated security=SSPI;data source=XU;persis" +
"t security info=False;initial catalog=jifei";
//
// sqlDataAdapter1
//
this.sqlDataAdapter1.DeleteCommand = this.sqlDeleteCommand1;
this.sqlDataAdapter1.InsertCommand = this.sqlInsertCommand1;
this.sqlDataAdapter1.SelectCommand = this.sqlSelectCommand1;
this.sqlDataAdapter1.TableMappings.AddRange(new System.Data.Common.DataTableMapping[] {
new System.Data.Common.DataTableMapping("Table", "帐户表", new System.Data.Common.DataColumnMapping[] {
new System.Data.Common.DataColumnMapping("条形码", "条形码"),
new System.Data.Common.DataColumnMapping("班级", "班级"),
new System.Data.Common.DataColumnMapping("姓名", "姓名"),
new System.Data.Common.DataColumnMapping("余额", "余额"),
new System.Data.Common.DataColumnMapping("锁定", "锁定")})});
this.sqlDataAdapter1.UpdateCommand = this.sqlUpdateCommand1;
//
// sqlDeleteCommand1
//
this.sqlDeleteCommand1.CommandText = "DELETE FROM 帐户表 WHERE (条形码 = @Original_条形码) AND (余额 = @Original_余额) AND (姓名 = @Or" +
"iginal_姓名) AND (班级 = @Original_班级) AND (锁定 = @Original_锁定)";
this.sqlDeleteCommand1.Connection = this.sqlConnection2;
this.sqlDeleteCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@Original_条形码", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, false, ((System.Byte)(0)), ((System.Byte)(0)), "条形码", System.Data.DataRowVersion.Original, null));
this.sqlDeleteCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@Original_余额", System.Data.SqlDbType.Decimal, 5, System.Data.ParameterDirection.Input, false, ((System.Byte)(5)), ((System.Byte)(2)), "余额", System.Data.DataRowVersion.Original, null));
this.sqlDeleteCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@Original_姓名", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, false, ((System.Byte)(0)), ((System.Byte)(0)), "姓名", System.Data.DataRowVersion.Original, null));
this.sqlDeleteCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@Original_班级", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, false, ((System.Byte)(0)), ((System.Byte)(0)), "班级", System.Data.DataRowVersion.Original, null));
this.sqlDeleteCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@Original_锁定", System.Data.SqlDbType.Bit, 1, System.Data.ParameterDirection.Input, false, ((System.Byte)(0)), ((System.Byte)(0)), "锁定", System.Data.DataRowVersion.Original, null));
//
// sqlConnection2
//
this.sqlConnection2.ConnectionString = "workstation id=XU;packet size=4096;integrated security=SSPI;data source=XU;persis" +
"t security info=False;initial catalog=jifei";
//
// sqlInsertCommand1
//
this.sqlInsertCommand1.CommandText = "INSERT INTO 帐户表(条形码, 班级, 姓名, 余额, 锁定) VALUES (@条形码, @班级, @姓名, @余额, @锁定); SELECT 条形" +
"码, 班级, 姓名, 余额, 锁定 FROM 帐户表 WHERE (条形码 = @条形码)";
this.sqlInsertCommand1.Connection = this.sqlConnection2;
this.sqlInsertCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@条形码", System.Data.SqlDbType.VarChar, 50, "条形码"));
this.sqlInsertCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@班级", System.Data.SqlDbType.VarChar, 50, "班级"));
this.sqlInsertCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@姓名", System.Data.SqlDbType.VarChar, 50, "姓名"));
this.sqlInsertCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@余额", System.Data.SqlDbType.Decimal, 5, System.Data.ParameterDirection.Input, false, ((System.Byte)(5)), ((System.Byte)(2)), "余额", System.Data.DataRowVersion.Current, null));
this.sqlInsertCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@锁定", System.Data.SqlDbType.Bit, 1, "锁定"));
//
// sqlSelectCommand1
//
this.sqlSelectCommand1.CommandText = "SELECT 条形码, 班级, 姓名, 余额, 锁定 FROM 帐户表";
this.sqlSelectCommand1.Connection = this.sqlConnection2;
//
// sqlUpdateCommand1
//
this.sqlUpdateCommand1.CommandText = "UPDATE 帐户表 SET 条形码 = @条形码, 班级 = @班级, 姓名 = @姓名, 余额 = @余额, 锁定 = @锁定 WHERE (条形码 = @O" +
"riginal_条形码) AND (余额 = @Original_余额) AND (姓名 = @Original_姓名) AND (班级 = @Original" +
"_班级) AND (锁定 = @Original_锁定); SELECT 条形码, 班级, 姓名, 余额, 锁定 FROM 帐户表 WHERE (条形码 = @" +
"条形码)";
this.sqlUpdateCommand1.Connection = this.sqlConnection2;
this.sqlUpdateCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@条形码", System.Data.SqlDbType.VarChar, 50, "条形码"));
this.sqlUpdateCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@班级", System.Data.SqlDbType.VarChar, 50, "班级"));
this.sqlUpdateCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@姓名", System.Data.SqlDbType.VarChar, 50, "姓名"));
this.sqlUpdateCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@余额", System.Data.SqlDbType.Decimal, 5, System.Data.ParameterDirection.Input, false, ((System.Byte)(5)), ((System.Byte)(2)), "余额", System.Data.DataRowVersion.Current, null));
this.sqlUpdateCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@锁定", System.Data.SqlDbType.Bit, 1, "锁定"));
this.sqlUpdateCommand1.Parameters.Add(new System.Data.SqlClient.SqlParameter("@Original_条形码", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, false, ((System.Byte)(0)), ((System.Byte)(0)), "条形码", System.Data.DataRowVersion.Original, null));
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -