📄 frmstuinfomanager.vb
字号:
Imports SchoolManage
Imports System.Data
Imports System.Data.SqlClient
Public Class FrmStuInfoManager
Inherits System.Windows.Forms.Form
Private sqlConn As SqlConnection
Private sqlComm As SqlCommand
Private daDate As SqlDataAdapter
Private dsDate As DataSet
Private flag As Int32 '标明添加还是修改还是能够查询
Private strSelect As String '查询框是否有值
Private tableNum As Int32 '查询框没值则为0,有值则为1
#Region " Windows 窗体设计器生成的代码 "
Public Sub New()
MyBase.New()
'该调用是 Windows 窗体设计器所必需的。
InitializeComponent()
End Sub
'窗体重写 dispose 以清理组件列表。
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 Label11 As System.Windows.Forms.Label
Friend WithEvents Label12 As System.Windows.Forms.Label
Friend WithEvents txtID As System.Windows.Forms.TextBox
Friend WithEvents txtName As System.Windows.Forms.TextBox
Friend WithEvents cmbSex As System.Windows.Forms.ComboBox
Friend WithEvents cmbSleep As System.Windows.Forms.ComboBox
Friend WithEvents txtHome As System.Windows.Forms.TextBox
Friend WithEvents txtCard As System.Windows.Forms.TextBox
Friend WithEvents cmbPolity As System.Windows.Forms.ComboBox
Friend WithEvents txtPhone As System.Windows.Forms.TextBox
Friend WithEvents cmbMoney As System.Windows.Forms.ComboBox
Friend WithEvents dgDate As System.Windows.Forms.DataGrid
Friend WithEvents Label14 As System.Windows.Forms.Label
Friend WithEvents cmbClass As System.Windows.Forms.ComboBox
Friend WithEvents labDuty As System.Windows.Forms.LinkLabel
Friend WithEvents datatimeBirthday As System.Windows.Forms.DateTimePicker
Friend WithEvents btnExit As System.Windows.Forms.Button
Friend WithEvents btnAdd As System.Windows.Forms.Button
Friend WithEvents btnUpdate As System.Windows.Forms.Button
Friend WithEvents btnDelete As System.Windows.Forms.Button
Friend WithEvents Label15 As System.Windows.Forms.Label
Friend WithEvents txtRemark As System.Windows.Forms.TextBox
Friend WithEvents Label16 As System.Windows.Forms.Label
Friend WithEvents datatimeCome As System.Windows.Forms.DateTimePicker
Friend WithEvents GroupBox1 As System.Windows.Forms.GroupBox
Friend WithEvents btnSave As System.Windows.Forms.Button
Friend WithEvents btnCancel As System.Windows.Forms.Button
Friend WithEvents cmbDuty As System.Windows.Forms.ComboBox
Friend WithEvents Label13 As System.Windows.Forms.Label
Friend WithEvents cmbMode As System.Windows.Forms.ComboBox
Friend WithEvents txtMode As System.Windows.Forms.TextBox
Friend WithEvents btnSelect 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.Label11 = New System.Windows.Forms.Label
Me.Label12 = New System.Windows.Forms.Label
Me.txtID = New System.Windows.Forms.TextBox
Me.txtName = New System.Windows.Forms.TextBox
Me.cmbSex = New System.Windows.Forms.ComboBox
Me.cmbSleep = New System.Windows.Forms.ComboBox
Me.txtHome = New System.Windows.Forms.TextBox
Me.datatimeBirthday = New System.Windows.Forms.DateTimePicker
Me.txtCard = New System.Windows.Forms.TextBox
Me.cmbPolity = New System.Windows.Forms.ComboBox
Me.txtPhone = New System.Windows.Forms.TextBox
Me.cmbMoney = New System.Windows.Forms.ComboBox
Me.dgDate = New System.Windows.Forms.DataGrid
Me.btnAdd = New System.Windows.Forms.Button
Me.btnUpdate = New System.Windows.Forms.Button
Me.btnDelete = New System.Windows.Forms.Button
Me.Label14 = New System.Windows.Forms.Label
Me.cmbClass = New System.Windows.Forms.ComboBox
Me.labDuty = New System.Windows.Forms.LinkLabel
Me.btnExit = New System.Windows.Forms.Button
Me.Label15 = New System.Windows.Forms.Label
Me.txtRemark = New System.Windows.Forms.TextBox
Me.Label16 = New System.Windows.Forms.Label
Me.datatimeCome = New System.Windows.Forms.DateTimePicker
Me.GroupBox1 = New System.Windows.Forms.GroupBox
Me.btnCancel = New System.Windows.Forms.Button
Me.btnSave = New System.Windows.Forms.Button
Me.cmbDuty = New System.Windows.Forms.ComboBox
Me.Label13 = New System.Windows.Forms.Label
Me.cmbMode = New System.Windows.Forms.ComboBox
Me.txtMode = New System.Windows.Forms.TextBox
Me.btnSelect = New System.Windows.Forms.Button
CType(Me.dgDate, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupBox1.SuspendLayout()
Me.SuspendLayout()
'
'Label1
'
Me.Label1.Font = New System.Drawing.Font("黑体", 15.75!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label1.Location = New System.Drawing.Point(182, 8)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(156, 26)
Me.Label1.TabIndex = 0
Me.Label1.Text = "学生信息管理"
Me.Label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'Label2
'
Me.Label2.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label2.Location = New System.Drawing.Point(24, 46)
Me.Label2.Name = "Label2"
Me.Label2.Size = New System.Drawing.Size(56, 22)
Me.Label2.TabIndex = 1
Me.Label2.Text = "学号:"
'
'Label3
'
Me.Label3.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label3.Location = New System.Drawing.Point(24, 137)
Me.Label3.Name = "Label3"
Me.Label3.Size = New System.Drawing.Size(64, 18)
Me.Label3.TabIndex = 2
Me.Label3.Text = "身份证:"
'
'Label4
'
Me.Label4.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label4.Location = New System.Drawing.Point(272, 104)
Me.Label4.Name = "Label4"
Me.Label4.Size = New System.Drawing.Size(66, 18)
Me.Label4.TabIndex = 3
Me.Label4.Text = "出生日期:"
'
'Label5
'
Me.Label5.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label5.Location = New System.Drawing.Point(368, 78)
Me.Label5.Name = "Label5"
Me.Label5.Size = New System.Drawing.Size(74, 20)
Me.Label5.TabIndex = 4
Me.Label5.Text = "寝室号:"
'
'Label6
'
Me.Label6.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label6.Location = New System.Drawing.Point(24, 104)
Me.Label6.Name = "Label6"
Me.Label6.Size = New System.Drawing.Size(56, 22)
Me.Label6.TabIndex = 5
Me.Label6.Text = "籍贯:"
'
'Label7
'
Me.Label7.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label7.Location = New System.Drawing.Point(192, 77)
Me.Label7.Name = "Label7"
Me.Label7.Size = New System.Drawing.Size(48, 15)
Me.Label7.TabIndex = 6
Me.Label7.Text = "职务:"
'
'Label8
'
Me.Label8.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label8.Location = New System.Drawing.Point(24, 76)
Me.Label8.Name = "Label8"
Me.Label8.Size = New System.Drawing.Size(56, 22)
Me.Label8.TabIndex = 7
Me.Label8.Text = "性别:"
'
'Label9
'
Me.Label9.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label9.Location = New System.Drawing.Point(272, 46)
Me.Label9.Name = "Label9"
Me.Label9.Size = New System.Drawing.Size(56, 22)
Me.Label9.TabIndex = 8
Me.Label9.Text = "姓名:"
'
'Label10
'
Me.Label10.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label10.Location = New System.Drawing.Point(274, 139)
Me.Label10.Name = "Label10"
Me.Label10.Size = New System.Drawing.Size(82, 16)
Me.Label10.TabIndex = 9
Me.Label10.Text = "联系电话:"
'
'Label11
'
Me.Label11.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label11.Location = New System.Drawing.Point(24, 232)
Me.Label11.Name = "Label11"
Me.Label11.Size = New System.Drawing.Size(68, 16)
Me.Label11.TabIndex = 10
Me.Label11.Text = "政治面貌:"
'
'Label12
'
Me.Label12.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.Label12.Location = New System.Drawing.Point(24, 198)
Me.Label12.Name = "Label12"
Me.Label12.Size = New System.Drawing.Size(70, 16)
Me.Label12.TabIndex = 11
Me.Label12.Text = "学费情况:"
'
'txtID
'
Me.txtID.Font = New System.Drawing.Font("宋体", 10.5!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.txtID.Location = New System.Drawing.Point(100, 42)
Me.txtID.Name = "txtID"
Me.txtID.Size = New System.Drawing.Size(152, 23)
Me.txtID.TabIndex = 12
Me.txtID.Text = ""
'
'txtName
'
Me.txtName.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.txtName.Location = New System.Drawing.Point(356, 42)
Me.txtName.Name = "txtName"
Me.txtName.Size = New System.Drawing.Size(176, 21)
Me.txtName.TabIndex = 13
Me.txtName.Text = ""
'
'cmbSex
'
Me.cmbSex.Font = New System.Drawing.Font("宋体", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(134, Byte))
Me.cmbSex.Location = New System.Drawing.Point(100, 74)
Me.cmbSex.Name = "cmbSex"
Me.cmbSex.Size = New System.Drawing.Size(80, 20)
Me.cmbSex.TabIndex = 14
'
'cmbSleep
'
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -