?? 查詢學生成績信息.frm
字號:
VERSION 5.00
Begin VB.Form 查詢學生成績信息
Caption = "Form1"
ClientHeight = 5040
ClientLeft = 60
ClientTop = 345
ClientWidth = 4875
LinkTopic = "Form1"
ScaleHeight = 5040
ScaleWidth = 4875
StartUpPosition = 3 '窗口缺省
Begin VB.TextBox Text3
Height = 615
Left = 1440
TabIndex = 6
Text = " "
Top = 1920
Width = 1335
End
Begin VB.TextBox Text2
Height = 615
Left = 1320
TabIndex = 4
Text = " "
Top = 840
Width = 1095
End
Begin VB.TextBox Text1
Height = 495
Left = 1320
TabIndex = 1
Text = " "
Top = 120
Width = 1095
End
Begin VB.Frame Frame1
Caption = "Frame1"
Height = 1695
Left = 240
TabIndex = 0
Top = 3120
Width = 3735
Begin VB.CommandButton Command3
Caption = " 清除"
Height = 495
Left = 720
TabIndex = 9
Top = 960
Width = 1695
End
Begin VB.CommandButton Command1
Caption = " 查詢"
Height = 495
Left = 240
TabIndex = 8
Top = 240
Width = 1215
End
Begin VB.CommandButton Command2
Caption = "退出查詢"
Height = 495
Left = 1800
TabIndex = 7
Top = 240
Width = 1215
End
End
Begin VB.Label Label3
Caption = "成績 "
Height = 735
Left = 120
TabIndex = 5
Top = 1920
Width = 1215
End
Begin VB.Label Label2
Caption = "課程編號"
Height = 615
Left = 120
TabIndex = 3
Top = 840
Width = 1095
End
Begin VB.Label Label1
Caption = "學號"
Height = 495
Left = 120
TabIndex = 2
Top = 120
Width = 855
End
End
Attribute VB_Name = "查詢學生成績信息"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim rs8 As New ADODB.Recordset
Private Sub Command1_Click()
If rs8.State <> 0 Then rs8.Close
rs8.Open "select* from 成績表", cnn, 3, 1
rs8.Find "學號 like '" & Text1 & "'"
If rs8.EOF Then
MsgBox "沒有此記錄!"
Text1 = ""
Exit Sub
Else
Text3 = rs8("成績")
Text2 = rs8("課程編號")
End If
End Sub
Private Sub Command2_Click()
Me.Hide
End Sub
Private Sub Command3_Click()
Text1 = ""
Text3 = ""
Text2 = ""
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -