📄 form8.vb
字号:
Me.TextBox1.Size = New System.Drawing.Size(88, 24)
Me.TextBox1.TabIndex = 17
Me.TextBox1.Text = ""
'
'Label1
'
Me.Label1.BackColor = System.Drawing.SystemColors.ControlText
Me.Label1.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label1.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label1.Location = New System.Drawing.Point(416, 56)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(120, 24)
Me.Label1.TabIndex = 16
Me.Label1.Text = "参加工作日期"
'
'TextBox7
'
Me.TextBox7.AutoSize = False
Me.TextBox7.BackColor = System.Drawing.SystemColors.ControlText
Me.TextBox7.ForeColor = System.Drawing.SystemColors.ControlLightLight
Me.TextBox7.Location = New System.Drawing.Point(544, 88)
Me.TextBox7.Name = "TextBox7"
Me.TextBox7.Size = New System.Drawing.Size(88, 24)
Me.TextBox7.TabIndex = 13
Me.TextBox7.Text = ""
'
'Label7
'
Me.Label7.BackColor = System.Drawing.SystemColors.ControlText
Me.Label7.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label7.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label7.Location = New System.Drawing.Point(16, 128)
Me.Label7.Name = "Label7"
Me.Label7.Size = New System.Drawing.Size(80, 24)
Me.Label7.TabIndex = 12
Me.Label7.Text = "职 称 名"
Me.Label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'TextBox6
'
Me.TextBox6.AutoSize = False
Me.TextBox6.BackColor = System.Drawing.SystemColors.ControlText
Me.TextBox6.ForeColor = System.Drawing.SystemColors.ControlLightLight
Me.TextBox6.Location = New System.Drawing.Point(296, 88)
Me.TextBox6.Name = "TextBox6"
Me.TextBox6.Size = New System.Drawing.Size(80, 24)
Me.TextBox6.TabIndex = 11
Me.TextBox6.Text = ""
'
'Label6
'
Me.Label6.BackColor = System.Drawing.SystemColors.ControlText
Me.Label6.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label6.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label6.Location = New System.Drawing.Point(16, 88)
Me.Label6.Name = "Label6"
Me.Label6.Size = New System.Drawing.Size(80, 24)
Me.Label6.TabIndex = 10
Me.Label6.Text = "住 址"
Me.Label6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'TextBox5
'
Me.TextBox5.AutoSize = False
Me.TextBox5.BackColor = System.Drawing.SystemColors.ControlText
Me.TextBox5.ForeColor = System.Drawing.SystemColors.ControlLightLight
Me.TextBox5.Location = New System.Drawing.Point(104, 88)
Me.TextBox5.Name = "TextBox5"
Me.TextBox5.Size = New System.Drawing.Size(88, 24)
Me.TextBox5.TabIndex = 9
Me.TextBox5.Text = ""
'
'Label5
'
Me.Label5.BackColor = System.Drawing.SystemColors.ControlText
Me.Label5.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label5.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label5.Location = New System.Drawing.Point(200, 88)
Me.Label5.Name = "Label5"
Me.Label5.Size = New System.Drawing.Size(80, 24)
Me.Label5.TabIndex = 8
Me.Label5.Text = "电 话"
Me.Label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'TextBox4
'
Me.TextBox4.AutoSize = False
Me.TextBox4.BackColor = System.Drawing.SystemColors.ControlText
Me.TextBox4.ForeColor = System.Drawing.SystemColors.ControlLightLight
Me.TextBox4.Location = New System.Drawing.Point(544, 56)
Me.TextBox4.Name = "TextBox4"
Me.TextBox4.Size = New System.Drawing.Size(88, 24)
Me.TextBox4.TabIndex = 7
Me.TextBox4.Text = ""
'
'Label4
'
Me.Label4.BackColor = System.Drawing.SystemColors.ControlText
Me.Label4.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label4.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label4.Location = New System.Drawing.Point(16, 56)
Me.Label4.Name = "Label4"
Me.Label4.Size = New System.Drawing.Size(80, 24)
Me.Label4.TabIndex = 6
Me.Label4.Text = "出生日期"
'
'TextBox3
'
Me.TextBox3.AutoSize = False
Me.TextBox3.BackColor = System.Drawing.SystemColors.ControlText
Me.TextBox3.ForeColor = System.Drawing.SystemColors.ControlLightLight
Me.TextBox3.Location = New System.Drawing.Point(104, 56)
Me.TextBox3.Name = "TextBox3"
Me.TextBox3.Size = New System.Drawing.Size(88, 24)
Me.TextBox3.TabIndex = 5
Me.TextBox3.Text = ""
'
'Label3
'
Me.Label3.BackColor = System.Drawing.SystemColors.ControlText
Me.Label3.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label3.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label3.Location = New System.Drawing.Point(448, 24)
Me.Label3.Name = "Label3"
Me.Label3.Size = New System.Drawing.Size(64, 24)
Me.Label3.TabIndex = 4
Me.Label3.Text = "性 别"
'
'TextBox12
'
Me.TextBox12.AutoSize = False
Me.TextBox12.BackColor = System.Drawing.SystemColors.MenuText
Me.TextBox12.ForeColor = System.Drawing.SystemColors.ControlLightLight
Me.TextBox12.Location = New System.Drawing.Point(152, 152)
Me.TextBox12.Name = "TextBox12"
Me.TextBox12.Size = New System.Drawing.Size(80, 24)
Me.TextBox12.TabIndex = 25
Me.TextBox12.Text = ""
'
'DataGrid1
'
Me.DataGrid1.BackgroundColor = System.Drawing.SystemColors.ControlText
Me.DataGrid1.CaptionBackColor = System.Drawing.SystemColors.ControlDarkDark
Me.DataGrid1.DataMember = ""
Me.DataGrid1.HeaderForeColor = System.Drawing.SystemColors.ControlText
Me.DataGrid1.Location = New System.Drawing.Point(32, 8)
Me.DataGrid1.Name = "DataGrid1"
Me.DataGrid1.Size = New System.Drawing.Size(568, 104)
Me.DataGrid1.TabIndex = 6
'
'Button3
'
Me.Button3.Cursor = System.Windows.Forms.Cursors.Hand
Me.Button3.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Button3.Image = CType(resources.GetObject("Button3.Image"), System.Drawing.Image)
Me.Button3.Location = New System.Drawing.Point(296, 376)
Me.Button3.Name = "Button3"
Me.Button3.Size = New System.Drawing.Size(64, 24)
Me.Button3.TabIndex = 8
Me.Button3.Text = "更 新"
'
'Button2
'
Me.Button2.Cursor = System.Windows.Forms.Cursors.Hand
Me.Button2.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Button2.Image = CType(resources.GetObject("Button2.Image"), System.Drawing.Image)
Me.Button2.Location = New System.Drawing.Point(536, 120)
Me.Button2.Name = "Button2"
Me.Button2.Size = New System.Drawing.Size(80, 40)
Me.Button2.TabIndex = 9
Me.Button2.Text = "显 示"
'
'Label12
'
Me.Label12.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label12.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label12.Image = CType(resources.GetObject("Label12.Image"), System.Drawing.Image)
Me.Label12.Location = New System.Drawing.Point(248, 152)
Me.Label12.Name = "Label12"
Me.Label12.Size = New System.Drawing.Size(208, 24)
Me.Label12.TabIndex = 26
Me.Label12.Text = "的职工进行内容更新"
'
'Label13
'
Me.Label13.Font = New System.Drawing.Font("宋体", 14.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label13.ForeColor = System.Drawing.SystemColors.ControlLight
Me.Label13.Image = CType(resources.GetObject("Label13.Image"), System.Drawing.Image)
Me.Label13.Location = New System.Drawing.Point(16, 152)
Me.Label13.Name = "Label13"
Me.Label13.Size = New System.Drawing.Size(128, 24)
Me.Label13.TabIndex = 27
Me.Label13.Text = "对职工编号为"
'
'SqlDataAdapter1
'
Me.SqlDataAdapter1.DeleteCommand = Me.SqlDeleteCommand1
Me.SqlDataAdapter1.InsertCommand = Me.SqlInsertCommand1
Me.SqlDataAdapter1.SelectCommand = Me.SqlSelectCommand1
Me.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("参加工作日期", "参加工作日期"), 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("工龄年数", "工龄年数"), New System.Data.Common.DataColumnMapping("编号1", "编号1")})})
Me.SqlDataAdapter1.UpdateCommand = Me.SqlUpdateCommand1
'
'SqlDeleteCommand1
'
Me.SqlDeleteCommand1.CommandText = "DELETE FROM 职工表 WHERE (编号 = @Original_编号) AND (住址 = @Original_住址 OR @Original_住址 " & _
"IS NULL AND 住址 IS NULL) AND (出生日期 = @Original_出生日期 OR @Original_出生日期 IS NULL AND" & _
" 出生日期 IS NULL) AND (参加工作日期 = @Original_参加工作日期 OR @Original_参加工作日期 IS NULL AND 参加" & _
"工作日期 IS NULL) AND (姓名 = @Original_姓名 OR @Original_姓名 IS NULL AND 姓名 IS NULL) AND" & _
" (工龄年数 = @Original_工龄年数 OR @Original_工龄年数 IS NULL AND 工龄年数 IS NULL) AND (性别 = @O" & _
"riginal_性别 OR @Original_性别 IS NULL AND 性别 IS NULL) AND (来自本单位的时间 = @Original_来自本" & _
"单位的时间 OR @Original_来自本单位的时间 IS NULL AND 来自本单位的时间 IS NULL) AND (电话 = @Original_电话" & _
" OR @Original_电话 IS NULL AND 电话 IS NULL) AND (编号1 = @Original_编号1 OR @Original_编" & _
"号1 IS NULL AND 编号1 IS NULL) AND (职称名 = @Original_职称名 OR @Original_职称名 IS NULL AN" & _
"D 职称名 IS NULL) AND (评定时间 = @Original_评定时间 OR @Original_评定时间 IS NULL AND 评定时间 IS " & _
"NULL)"
Me.SqlDeleteCommand1.Connection = Me.SqlConnection1
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_编号", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "编号", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_住址", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "住址", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_出生日期", System.Data.SqlDbType.DateTime, 8, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "出生日期", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_参加工作日期", System.Data.SqlDbType.DateTime, 8, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "参加工作日期", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_姓名", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "姓名", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_工龄年数", System.Data.SqlDbType.Int, 4, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "工龄年数", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_性别", System.Data.SqlDbType.VarChar, 10, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "性别", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_来自本单位的时间", System.Data.SqlDbType.DateTime, 8, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "来自本单位的时间", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_电话", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "电话", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_编号1", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "编号1", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_职称名", System.Data.SqlDbType.VarChar, 50, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "职称名", System.Data.DataRowVersion.Original, Nothing))
Me.SqlDeleteCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@Original_评定时间", System.Data.SqlDbType.DateTime, 8, System.Data.ParameterDirection.Input, False, CType(0, Byte), CType(0, Byte), "评定时间", System.Data.DataRowVersion.Original, Nothing))
'
'SqlConnection1
'
Me.SqlConnection1.ConnectionString = "workstation id=FB60FF2059274FF;packet size=4096;integrated security=SSPI;initial " & _
"catalog=人事管理系统;persist security info=False"
'
'SqlInsertCommand1
'
Me.SqlInsertCommand1.CommandText = "INSERT INTO 职工表(编号, 姓名, 性别, 出生日期, 参加工作日期, 住址, 电话, 来自本单位的时间, 职称名, 评定时间, 工龄年数, 编号1)" & _
" VALUES (@编号, @姓名, @性别, @出生日期, @参加工作日期, @住址, @电话, @来自本单位的时间, @职称名, @评定时间, @工龄年数," & _
" @编号1); SELECT 编号, 姓名, 性别, 出生日期, 参加工作日期, 住址, 电话, 来自本单位的时间, 职称名, 评定时间, 工龄年数, 编号1 " & _
"FROM 职工表 WHERE (编号 = @编号)"
Me.SqlInsertCommand1.Connection = Me.SqlConnection1
Me.SqlInsertCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@编号", System.Data.SqlDbType.VarChar, 50, "编号"))
Me.SqlInsertCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@姓名", System.Data.SqlDbType.VarChar, 50, "姓名"))
Me.SqlInsertCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@性别", System.Data.SqlDbType.VarChar, 10, "性别"))
Me.SqlInsertCommand1.Parameters.Add(New System.Data.SqlClient.SqlParameter("@出生日期", System.Data.SqlDbType.DateTime, 8, "出生日期"))
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -