?? tikugli.frm
字號:
VERSION 5.00
Begin VB.Form tikugli
BackColor = &H8000000A&
Caption = " 題庫管理"
ClientHeight = 6540
ClientLeft = 165
ClientTop = 450
ClientWidth = 8625
LinkTopic = "Form2"
ScaleHeight = 6540
ScaleWidth = 8625
StartUpPosition = 2 '屏幕中心
Begin VB.ComboBox Combo1
Height = 300
Left = 0
TabIndex = 8
Text = "Combo1"
Top = 3600
Visible = 0 'False
Width = 1215
End
Begin VB.ComboBox Combo2
Height = 300
Left = 0
TabIndex = 7
Text = "Combo2"
Top = 4800
Visible = 0 'False
Width = 1215
End
Begin VB.Label Label7
BackStyle = 0 'Transparent
Caption = "知識點"
Height = 495
Left = 5400
TabIndex = 6
Top = 2160
Visible = 0 'False
Width = 495
End
Begin VB.Label Label6
BackStyle = 0 'Transparent
Caption = "難度"
Height = 375
Left = 1920
TabIndex = 5
Top = 2160
Visible = 0 'False
Width = 495
End
Begin VB.Label Label5
BackStyle = 0 'Transparent
Caption = "分值"
Height = 495
Left = 5280
TabIndex = 4
Top = 720
Visible = 0 'False
Width = 735
End
Begin VB.Label Label4
BackStyle = 0 'Transparent
Caption = "題號"
Height = 375
Left = 2040
TabIndex = 3
Top = 720
Visible = 0 'False
Width = 495
End
Begin VB.Label Label3
BackStyle = 0 'Transparent
Caption = "題目區"
Height = 615
Left = 2040
TabIndex = 2
Top = 3480
Visible = 0 'False
Width = 735
End
Begin VB.Label Label2
BackStyle = 0 'Transparent
Caption = "請選擇題型"
Height = 255
Left = 0
TabIndex = 1
Top = 4440
Visible = 0 'False
Width = 975
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = " 請選擇科目"
Height = 375
Left = 0
TabIndex = 0
Top = 3120
Visible = 0 'False
Width = 1095
End
Begin VB.Image Image1
Height = 2850
Left = 0
Picture = "tikugli.frx":0000
Top = 120
Width = 2145
End
Begin VB.Menu file
Caption = "文件"
Begin VB.Menu new
Caption = "新建"
Begin VB.Menu shujuku
Caption = "數據庫"
Index = 0
End
Begin VB.Menu shujubiao
Caption = "數據表"
Index = 0
End
End
End
Begin VB.Menu xinxi
Caption = "信息"
Begin VB.Menu liulan
Caption = "瀏覽"
End
Begin VB.Menu update
Caption = "更新"
End
Begin VB.Menu add
Caption = "添加"
End
Begin VB.Menu delete
Caption = "刪除"
End
Begin VB.Menu modify
Caption = "修改"
End
End
Begin VB.Menu h
Caption = "幫助"
Begin VB.Menu help
Caption = "help"
Shortcut = {F1}
End
End
End
Attribute VB_Name = "tikugli"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub add_Click()
For i = 0 To 4
DataGrid1(i).Visible = False
Text1(i).Visible = False
Text2(i).Visible = True
Text2(i).Text = " "
Next i
Label1.Visible = True
Label2.Visible = True
Label3.Visible = True
Label4.Visible = True
Label5.Visible = True
Label6.Visible = True
Label7.Visible = True
Combo1.Visible = True
Combo2.Visible = True
End Sub
Private Sub Combo2_Click()
i = Combo2.ListIndex
Text1(i).ZOrder
DataGrid1(i).ZOrder
End Sub
Private Sub delete_Click()
Dim r As Integer
r = MsgBox("確定刪除當前記錄?", vbExclamation + vbYesNo)
If r = vbYes Then
i = Combo2.ListIndex
Adodc1(i).Recordset.delete
Adodc1(i).Recordset.MoveNext
If Adodc1(i).Recordset.EOF Then
Adodc1(i).Recordset.MoveLast
End If
End If
End Sub
Private Sub Form_Load()
For i = 0 To 4
Adodc1(i).ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + App.Path + "\shujuku.mdb;"
Next
Adodc1(0).RecordSource = "選擇題"
Adodc1(1).RecordSource = "完型填空"
Adodc1(2).RecordSource = "書面表達"
Adodc1(3).RecordSource = "短文改錯"
Adodc1(4).RecordSource = "閱讀理解"
For j = 0 To 4
Set Text1(j).DataSource = Adodc1(j)
Text1(j).DataField = "題目"
Set DataGrid1(j).DataSource = Adodc1(j)
Next
Combo1.Clear
Combo1.AddItem "英語"
Combo1.AddItem "數學"
Combo1.Text = "科目"
End Sub
Private Sub Combo1_Click()
Select Case Combo1.Text
Case "英語"
Combo2.Clear
Combo2.AddItem "選擇題"
Combo2.AddItem "完型填空"
Combo2.AddItem "書面表達"
Combo2.AddItem "短文改錯"
Combo2.AddItem "閱讀理解"
Combo2.Text = "題型"
Case "數學"
Combo2.Clear
Combo2.AddItem "選擇題"
Combo2.AddItem "填空"
Combo2.AddItem "解答題"
Combo2.Text = "題型"
End Select
End Sub
Private Sub help_Click()
Load help
End Sub
Private Sub liulan_Click()
Label1.Visible = True
Label2.Visible = True
Label3.Visible = True
Label4.Visible = False
Label5Visible = False
Label6Visible = False
Label7.Visible = False
For i = 0 To 4
DataGrid1(i).Visible = True
Text1(i).Visible = True
Combo1.Visible = True
Combo2.Visible = True
Text2(i).Visible = False
Next i
Label3.Visible = True
End Sub
Private Sub update_Click()
i = Combo2.ListIndex
Adodc1(i).Recordset.AddNew
Adodc1(i).Recordset("題號") = CInt(Text2(0).Text)
If i = 0 Or i = 4 Then
Adodc1(i).Recordset("知識點") = (Text2(3).Text)
End If
Adodc1(i).Recordset("分值") = CInt(Text2(1).Text)
Adodc1(i).Recordset("難度") = Text2(2).Text
Adodc1(i).Recordset("題目") = Text2(4).Text
Label1.Visible = True
Label2.Visible = True
Label3.Visible = True
Label4.Visible = False
Label5Visible = False
Label6Visible = False
Label7.Visible = False
For i = 0 To 4
DataGrid1(i).Visible = True
Text1(i).Visible = True
Combo1.Visible = True
Combo2.Visible = True
Text2(i).Visible = False
Next i
Label3.Visible = True
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -