?? 課程統計.frm
字號:
VERSION 5.00
Begin VB.Form Frm_CountGrean
BorderStyle = 1 'Fixed Single
Caption = "課程統計分析"
ClientHeight = 2205
ClientLeft = 45
ClientTop = 330
ClientWidth = 7230
Icon = "課程統計.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 2205
ScaleWidth = 7230
StartUpPosition = 2 '屏幕中心
Visible = 0 'False
Begin VB.CommandButton Command2
Caption = "退出"
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 4320
TabIndex = 7
Top = 1560
Width = 1215
End
Begin VB.CommandButton Command1
Caption = "統計打印"
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 1920
TabIndex = 6
Top = 1560
Width = 1215
End
Begin VB.TextBox Text3
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 1680
TabIndex = 5
Text = "Text3"
Top = 960
Width = 2295
End
Begin VB.CheckBox Check4
Caption = "課程名稱:"
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 240
TabIndex = 4
Top = 960
Width = 1455
End
Begin VB.ComboBox Combo1
BeginProperty Font
Name = "宋體"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 360
Left = 5760
TabIndex = 3
Text = "Combo1"
Top = 360
Width = 1095
End
Begin VB.CheckBox Check2
Caption = "課程性質:"
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 4440
TabIndex = 2
Top = 360
Width = 1575
End
Begin VB.TextBox Text1
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 1200
TabIndex = 1
Text = "Text1"
Top = 360
Width = 2295
End
Begin VB.CheckBox Check1
Caption = "專業:"
BeginProperty Font
Name = "宋體"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 240
TabIndex = 0
Top = 360
Width = 975
End
End
Attribute VB_Name = "Frm_CountGrean"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Dim SQLoriginal As String
Dim SQLadd As String
Dim SQLorder As String
Dim strSql As String
SQLoriginal = "SELECT * FROM 課程表 "
SQLadd = "WHERE 專業=專業 AND 課程名稱=課程名稱 "
SQLorder = ""
If Check1.Value = 1 And Not IsNull(Text1) Then
SQLadd = SQLadd + "and 專業='" + Text1 + "'"
End If
If Check2.Value = 1 And Not IsNull(Combo1) Then
SQLadd = SQLadd + "and 課程性質='" + Combo1 + "'"
End If
'If Check3.Value = 1 And Not IsNumeric(Text2) Then
'SQLadd = SQLadd + "and 課時='" + Text2 + "'"
'End If
If Check4.Value = 1 And Not IsNull(Text3) Then
SQLadd = SQLadd + "and 課程名稱='" + Text3 + "'"
End If
strSql = SQLoriginal + SQLadd + SQLorde
If Dat_Main.rsDat_Grean.State = 1 Then
Dat_Main.rsDat_Grean.Close
End If
Dat_Main.rsDat_Grean.Open strSql
Dat_Grean.Show vbModal
Text1.Text = ""
Combo1.Text = ""
'Text2.Text = ""
Text3.Text = ""
End Sub
Private Sub Command2_Click()
Unload Me
End Sub
Private Sub Form_Load()
Text1.Text = ""
'Text2.Text = ""
Text3.Text = ""
Combo1.Text = ""
Combo1.AddItem ("必修")
Combo1.AddItem ("選修")
Combo1.AddItem ("自開")
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -