?? studentlixiao.frm
字號:
VERSION 5.00
Begin VB.Form studentlixiao
Caption = "學(xué)生離校注銷"
ClientHeight = 4065
ClientLeft = 60
ClientTop = 450
ClientWidth = 7830
MDIChild = -1 'True
ScaleHeight = 4065
ScaleWidth = 7830
Begin VB.Frame Frame1
Height = 2775
Left = 480
TabIndex = 5
Top = 840
Width = 6855
Begin VB.TextBox Text2
Height = 375
Left = 1800
TabIndex = 2
Top = 1680
Width = 2415
End
Begin VB.TextBox Text1
Height = 375
Left = 1800
TabIndex = 1
Top = 720
Width = 2415
End
Begin VB.CommandButton Command2
Caption = "取消"
Height = 375
Left = 4920
TabIndex = 4
Top = 1560
Width = 1095
End
Begin VB.CommandButton Command1
Caption = "確定"
Default = -1 'True
Height = 375
Left = 4920
TabIndex = 3
Top = 720
Width = 1095
End
Begin VB.Label Label3
AutoSize = -1 'True
Caption = "學(xué)生姓名:"
Height = 180
Left = 600
TabIndex = 7
Top = 1800
Width = 900
End
Begin VB.Label Label2
AutoSize = -1 'True
Caption = "學(xué)生學(xué)號:"
Height = 180
Left = 600
TabIndex = 6
Top = 840
Width = 900
End
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "注銷離校學(xué)生"
BeginProperty Font
Name = "幼圓"
Size = 18
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 360
Left = 2760
TabIndex = 0
Top = 240
Width = 2160
End
End
Attribute VB_Name = "studentlixiao"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public studentname As String
Public mrc As ADODB.Recordset
Private Sub Command1_Click()
Dim ok1 As String
Dim txtSQL As String
Dim MsgText As String
studenname = ""
'////////////////////////////////////
If Trim(Me.Text2.Text = "") Then
MsgBox "姓名不可為空,請輸入!", vbOKOnly + vbExclamation, "警告"
Me.Text2.SetFocus
Exit Sub
End If
If Not IsNumeric(Trim(Me.Text1.Text)) Then
MsgBox "學(xué)號必須為數(shù)字型!,請重新輸入!", vbOKOnly + vbExclamation, "警告"
Me.Text1.Text = ""
Me.Text1.SetFocus
Exit Sub
End If
If Trim(Me.Text1.Text = "") Then
MsgBox "學(xué)號不能為空,請重新輸入學(xué)號!", vbOKOnly + vbExclamation, "警告"
Me.Text1.SetFocus
Exit Sub
Else
txtSQL = "select * from student_if where student_ID = '" & Me.Text1.Text & "'"
Set mrc = ExecuteSQL(txtSQL, MsgText)
If mrc.EOF = True Then
MsgBox "沒有這個學(xué)生,請重新輸入學(xué)號!", vbOKOnly + vbExclamation, "警告"
Me.Text1.Text = ""
Me.Text1.SetFocus
Exit Sub
Else
If Trim(mrc.Fields(1)) = Trim(Me.Text2.Text) Then
X = MsgBox("確定要注銷這個學(xué)生嗎?", 35, "是否注銷")
If X = 6 Then
mrc.Delete
mrc.Update
mrc.Close
Me.Text1.Text = ""
Me.Text2.Text = ""
ElseIf X = 7 Then
Me.Text1.Text = ""
Me.Text2.Text = ""
Exit Sub
ElseIf X = 2 Then
Me.Hide
End If
studentname = Trim(Me.Text1.Text)
Else
MsgBox "輸入姓名不正確,請重新輸入!", vbOKOnly + vbExclamation, "警告"
Me.Text2.SetFocus
Me.Text2.Text = ""
Exit Sub
End If
End If
End If
Exit Sub
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Form_Load()
Call loading
End Sub
Private Sub loading()
Me.Height = 4575
Me.Top = 0
Me.Left = 0
Me.Width = 8000
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 2 Then
PopupMenu mainForm1.ABC
End If
End Sub
Private Sub Frame1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 2 Then
PopupMenu mainForm1.ABC
End If
End Sub
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -