📄 frmmanadd.vb
字号:
Public Class Frmmanadd
Inherits System.Windows.Forms.Form
Private Sub setall1()
Cbjobname.Enabled = True
Txtrenshu.Enabled = True
Cbmanbumen.Enabled = True
Txtapplycompany.Enabled = True
Txtapplycompanyaddr.Enabled = True
Txtapplytime.Enabled = True
Txtapplycompanyphone.Enabled = True
Txtmodifytime.Enabled = True
Txtmodifycompany.Enabled = True
Txtmodifycompanyphone.Enabled = True
End Sub
Private Sub setall2()
Cbjobname.Enabled = False
Txtrenshu.Enabled = False
Cbmanbumen.Enabled = False
Txtapplycompany.Enabled = False
Txtapplycompanyaddr.Enabled = False
Txtapplytime.Enabled = False
Txtapplycompanyphone.Enabled = False
Txtmodifytime.Enabled = False
Txtmodifycompany.Enabled = False
Txtmodifycompanyphone.Enabled = False
End Sub
Private Sub setall3()
Cbjobname.Text = ""
Txtrenshu.Text = ""
Cbmanbumen.Text = ""
Txtapplycompany.Text = ""
Txtapplycompanyaddr.Text = ""
Txtapplytime.Text = ""
Txtapplycompanyphone.Text = ""
Txtmodifytime.Text = ""
Txtmodifycompany.Text = ""
Txtmodifycompanyphone.Text = ""
End Sub
#Region " Windows 窗体设计器生成的代码 "
Public Sub New()
MyBase.New()
'该调用是 Windows 窗体设计器所必需的。
InitializeComponent()
'在 InitializeComponent() 调用之后添加任何初始化
End Sub
'窗体重写处置以清理组件列表。
Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub
'Windows 窗体设计器所必需的
Private components As System.ComponentModel.IContainer
'注意:以下过程是 Windows 窗体设计器所必需的
'可以使用 Windows 窗体设计器修改此过程。
'不要使用代码编辑器修改它。
Friend WithEvents Label1 As System.Windows.Forms.Label
Friend WithEvents Label2 As System.Windows.Forms.Label
Friend WithEvents Label3 As System.Windows.Forms.Label
Friend WithEvents Label4 As System.Windows.Forms.Label
Friend WithEvents Label5 As System.Windows.Forms.Label
Friend WithEvents Label6 As System.Windows.Forms.Label
Friend WithEvents Label7 As System.Windows.Forms.Label
Friend WithEvents Label8 As System.Windows.Forms.Label
Friend WithEvents Label9 As System.Windows.Forms.Label
Friend WithEvents Label10 As System.Windows.Forms.Label
Friend WithEvents Cbjobname As System.Windows.Forms.ComboBox
Friend WithEvents Txtrenshu As System.Windows.Forms.TextBox
Friend WithEvents Cbmanbumen As System.Windows.Forms.ComboBox
Friend WithEvents Txtapplycompany As System.Windows.Forms.TextBox
Friend WithEvents Txtapplycompanyaddr As System.Windows.Forms.TextBox
Friend WithEvents Txtapplytime As System.Windows.Forms.TextBox
Friend WithEvents Txtapplycompanyphone As System.Windows.Forms.TextBox
Friend WithEvents Txtmodifytime As System.Windows.Forms.TextBox
Friend WithEvents Txtmodifycompany As System.Windows.Forms.TextBox
Friend WithEvents Txtmodifycompanyphone As System.Windows.Forms.TextBox
Friend WithEvents Btadd As System.Windows.Forms.Button
Friend WithEvents Btexit As System.Windows.Forms.Button
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
Me.Label1 = New System.Windows.Forms.Label()
Me.Label2 = New System.Windows.Forms.Label()
Me.Label3 = New System.Windows.Forms.Label()
Me.Label4 = New System.Windows.Forms.Label()
Me.Label5 = New System.Windows.Forms.Label()
Me.Label6 = New System.Windows.Forms.Label()
Me.Label7 = New System.Windows.Forms.Label()
Me.Label8 = New System.Windows.Forms.Label()
Me.Label9 = New System.Windows.Forms.Label()
Me.Label10 = New System.Windows.Forms.Label()
Me.Cbjobname = New System.Windows.Forms.ComboBox()
Me.Txtrenshu = New System.Windows.Forms.TextBox()
Me.Cbmanbumen = New System.Windows.Forms.ComboBox()
Me.Txtapplycompany = New System.Windows.Forms.TextBox()
Me.Txtapplycompanyaddr = New System.Windows.Forms.TextBox()
Me.Txtapplytime = New System.Windows.Forms.TextBox()
Me.Txtapplycompanyphone = New System.Windows.Forms.TextBox()
Me.Txtmodifytime = New System.Windows.Forms.TextBox()
Me.Txtmodifycompany = New System.Windows.Forms.TextBox()
Me.Txtmodifycompanyphone = New System.Windows.Forms.TextBox()
Me.Btadd = New System.Windows.Forms.Button()
Me.Btexit = New System.Windows.Forms.Button()
Me.SuspendLayout()
'
'Label1
'
Me.Label1.Location = New System.Drawing.Point(24, 32)
Me.Label1.Name = "Label1"
Me.Label1.TabIndex = 0
Me.Label1.Text = "职业名称:"
'
'Label2
'
Me.Label2.Location = New System.Drawing.Point(24, 72)
Me.Label2.Name = "Label2"
Me.Label2.TabIndex = 1
Me.Label2.Text = "人 数:"
'
'Label3
'
Me.Label3.Location = New System.Drawing.Point(24, 112)
Me.Label3.Name = "Label3"
Me.Label3.TabIndex = 2
Me.Label3.Text = "隶属部门:"
'
'Label4
'
Me.Label4.Location = New System.Drawing.Point(24, 152)
Me.Label4.Name = "Label4"
Me.Label4.TabIndex = 3
Me.Label4.Text = "申报单位:"
'
'Label5
'
Me.Label5.Location = New System.Drawing.Point(24, 192)
Me.Label5.Name = "Label5"
Me.Label5.TabIndex = 4
Me.Label5.Text = "申报单位地址:"
'
'Label6
'
Me.Label6.Location = New System.Drawing.Point(352, 40)
Me.Label6.Name = "Label6"
Me.Label6.TabIndex = 5
Me.Label6.Text = "申报时间:"
'
'Label7
'
Me.Label7.Location = New System.Drawing.Point(352, 80)
Me.Label7.Name = "Label7"
Me.Label7.TabIndex = 6
Me.Label7.Text = "申报单位电话:"
'
'Label8
'
Me.Label8.Location = New System.Drawing.Point(352, 120)
Me.Label8.Name = "Label8"
Me.Label8.TabIndex = 7
Me.Label8.Text = "修改时间:"
'
'Label9
'
Me.Label9.Location = New System.Drawing.Point(352, 160)
Me.Label9.Name = "Label9"
Me.Label9.TabIndex = 8
Me.Label9.Text = "修改单位:"
'
'Label10
'
Me.Label10.Location = New System.Drawing.Point(352, 200)
Me.Label10.Name = "Label10"
Me.Label10.TabIndex = 9
Me.Label10.Text = "修改单位电话:"
'
'Cbjobname
'
Me.Cbjobname.Enabled = False
Me.Cbjobname.Items.AddRange(New Object() {"医师", "护士", "民警", "武警", "交警", "消防队员", "水利工程师", "环卫工人", "环境污染防治人员", "气象数据采集员", "气象数据分析员", "地质灾害数据采集员", "地质灾害数据分析员"})
Me.Cbjobname.Location = New System.Drawing.Point(120, 32)
Me.Cbjobname.Name = "Cbjobname"
Me.Cbjobname.Size = New System.Drawing.Size(121, 20)
Me.Cbjobname.TabIndex = 10
'
'Txtrenshu
'
Me.Txtrenshu.Enabled = False
Me.Txtrenshu.Location = New System.Drawing.Point(120, 72)
Me.Txtrenshu.Name = "Txtrenshu"
Me.Txtrenshu.TabIndex = 11
Me.Txtrenshu.Text = ""
'
'Cbmanbumen
'
Me.Cbmanbumen.Enabled = False
Me.Cbmanbumen.Items.AddRange(New Object() {"医疗部门", "公安部门", "教育部门", "城管部门", "消防部门", "林业部门", "水利部门", "环卫部门", "气象部门", "化学品监管及处理部门", "交通部门", "地质灾害防预部门"})
Me.Cbmanbumen.Location = New System.Drawing.Point(120, 112)
Me.Cbmanbumen.Name = "Cbmanbumen"
Me.Cbmanbumen.Size = New System.Drawing.Size(121, 20)
Me.Cbmanbumen.TabIndex = 12
'
'Txtapplycompany
'
Me.Txtapplycompany.Enabled = False
Me.Txtapplycompany.Location = New System.Drawing.Point(120, 152)
Me.Txtapplycompany.Name = "Txtapplycompany"
Me.Txtapplycompany.Size = New System.Drawing.Size(160, 21)
Me.Txtapplycompany.TabIndex = 13
Me.Txtapplycompany.Text = ""
'
'Txtapplycompanyaddr
'
Me.Txtapplycompanyaddr.Enabled = False
Me.Txtapplycompanyaddr.Location = New System.Drawing.Point(120, 192)
Me.Txtapplycompanyaddr.Name = "Txtapplycompanyaddr"
Me.Txtapplycompanyaddr.Size = New System.Drawing.Size(200, 21)
Me.Txtapplycompanyaddr.TabIndex = 14
Me.Txtapplycompanyaddr.Text = ""
'
'Txtapplytime
'
Me.Txtapplytime.Enabled = False
Me.Txtapplytime.Location = New System.Drawing.Point(440, 40)
Me.Txtapplytime.Name = "Txtapplytime"
Me.Txtapplytime.Size = New System.Drawing.Size(112, 21)
Me.Txtapplytime.TabIndex = 15
Me.Txtapplytime.Text = ""
'
'Txtapplycompanyphone
'
Me.Txtapplycompanyphone.Enabled = False
Me.Txtapplycompanyphone.Location = New System.Drawing.Point(440, 80)
Me.Txtapplycompanyphone.Name = "Txtapplycompanyphone"
Me.Txtapplycompanyphone.Size = New System.Drawing.Size(112, 21)
Me.Txtapplycompanyphone.TabIndex = 16
Me.Txtapplycompanyphone.Text = ""
'
'Txtmodifytime
'
Me.Txtmodifytime.Enabled = False
Me.Txtmodifytime.Location = New System.Drawing.Point(440, 120)
Me.Txtmodifytime.Name = "Txtmodifytime"
Me.Txtmodifytime.Size = New System.Drawing.Size(112, 21)
Me.Txtmodifytime.TabIndex = 17
Me.Txtmodifytime.Text = ""
'
'Txtmodifycompany
'
Me.Txtmodifycompany.Enabled = False
Me.Txtmodifycompany.Location = New System.Drawing.Point(440, 152)
Me.Txtmodifycompany.Name = "Txtmodifycompany"
Me.Txtmodifycompany.Size = New System.Drawing.Size(112, 21)
Me.Txtmodifycompany.TabIndex = 18
Me.Txtmodifycompany.Text = ""
'
'Txtmodifycompanyphone
'
Me.Txtmodifycompanyphone.Enabled = False
Me.Txtmodifycompanyphone.Location = New System.Drawing.Point(440, 192)
Me.Txtmodifycompanyphone.Name = "Txtmodifycompanyphone"
Me.Txtmodifycompanyphone.Size = New System.Drawing.Size(112, 21)
Me.Txtmodifycompanyphone.TabIndex = 19
Me.Txtmodifycompanyphone.Text = ""
'
'Btadd
'
Me.Btadd.Location = New System.Drawing.Point(120, 248)
Me.Btadd.Name = "Btadd"
Me.Btadd.Size = New System.Drawing.Size(96, 32)
Me.Btadd.TabIndex = 20
Me.Btadd.Text = "添加"
'
'Btexit
'
Me.Btexit.Location = New System.Drawing.Point(352, 248)
Me.Btexit.Name = "Btexit"
Me.Btexit.Size = New System.Drawing.Size(96, 32)
Me.Btexit.TabIndex = 22
Me.Btexit.Text = "退 出"
'
'Frmmanadd
'
Me.AutoScaleBaseSize = New System.Drawing.Size(6, 14)
Me.ClientSize = New System.Drawing.Size(576, 309)
Me.Controls.AddRange(New System.Windows.Forms.Control() {Me.Btexit, Me.Btadd, Me.Txtmodifycompanyphone, Me.Txtmodifycompany, Me.Txtmodifytime, Me.Txtapplycompanyphone, Me.Txtapplytime, Me.Txtapplycompanyaddr, Me.Txtapplycompany, Me.Cbmanbumen, Me.Txtrenshu, Me.Cbjobname, Me.Label10, Me.Label9, Me.Label8, Me.Label7, Me.Label6, Me.Label5, Me.Label4, Me.Label3, Me.Label2, Me.Label1})
Me.Name = "Frmmanadd"
Me.Text = "应急人员信息添加"
Me.ResumeLayout(False)
End Sub
#End Region
Private Sub Btexit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btexit.Click
Dim newFrmmain As New Frmmain()
newFrmmain.Show()
Me.Hide()
End Sub
Private Sub Frmmanadd_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Private Sub Btadd_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btadd.Click
If Btadd.Text = "添加" Then
setall1()
setall3()
Btexit.Enabled = False
Btadd.Text = "确定"
Return
End If
If Btadd.Text = "确定" Then
MessageBox.Show("您的用户信息已经添加成功!")
setall2()
Btexit.Enabled = True
Btadd.Text = "添加"
setall3()
Return
End If
End Sub
End Class
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -