【正文】
H8000000E Next = amp。 Set mrc = ExecuteSQL(tSQL, MsgText) If = False Then For i = 1 To 8 Text1(i) = (i) Next Text1(4) = 0 txtSQL = select * from class_Form Set mrc = ExecuteSQL(txtSQL, MsgText) If = False Then With Combo1 Do While Not .AddItem Trim(mrc!class_NO) Loop End With End If If Label1(2).BackColor = amp。 Trim(Text1(Index)) amp。HFFFFFF Then If Index = 0 Then tSQL = select * from student_Form where student_NO=39。 Set mrc = ExecuteSQL(txtSQL, MsgText) If = False Then MsgBox 學(xué)號(hào)不能重復(fù), vbOKOnly, 警告 Text1(0).SetFocus Exit Sub End If txtSQL = select * from student_Form Set mrc = ExecuteSQL(txtSQL, MsgText) (0) = Trim(Text1(0)) (1) = Trim(Text1(1)) (2) = Trim(Text1(2)) (3) = Trim(Text1(3)) (4) = Trim(Text1(4)) (5) = Trim(Text1(5)) (6) = Trim(Text1(6)) (7) = Trim(Text1(7)) If Text1(8) = Label2(8).Caption Then (8) = Else (8) = Trim(Text1(8)) End If MsgBox 學(xué)籍信息添加成功, vbOKOnly, 提示 With MSFlexGrid1 .Rows = .Rows + 1 .TextMatrix(.Rows 1, 0) = Trim(Text1(0)) .TextMatrix(.Rows 1, 1) = Trim(Text1(1)) .TextMatrix(.Rows 1, 2) = Trim(Text1(2)) .TextMatrix(.Rows 1, 3) = Trim(Text1(3)) .TextMatrix(.Rows 1, 4) = Trim(Text1(4)) .TextMatrix(.Rows 1, 5) = Trim(Text1(5)) .TextMatrix(.Rows 1, 6) = Trim(Text1(6)) .TextMatrix(.Rows 1, 7) = Trim(Text1(7)) If Text1(8) Label2(8).Caption Then .TextMatrix(.Rows 1, 8) = Trim(Text1(8)) End If End With = 1 TextDcolorEnd SubPrivate Sub Text1_Change(Index As Integer) If Label1(2).BackColor = amp。 Trim(Text1(0)) amp。 !, vbOKOnly, 提示 Exit Sub End If End If Next If IsDate(Text1(3)) = False Then MsgBox 出生日期應(yīng)為日期格式((yyyymmdd)!, vbOKOnly, 警告 Text1(3).SetFocus Exit Sub End If If IsDate(Text1(6)) = False Then MsgBox 入學(xué)日期應(yīng)為日期格式(yyyymmdd)!, vbOKOnly, 警告 Text1(6).SetFocus Exit Sub End If txtSQL = select * from student_Form where student_NO=39。 !, vbOKOnly, 提示 Text1(i).SetFocus Exit Sub End If Else If Text1(i) = Label2(i).Caption Then MsgBox 請(qǐng) amp。HFFFFFF End If End IfEnd SubPrivate Sub Command1_Click() Dim txtSQL As String For i = 0 To 7 If i 4 Then If Text1(i) = Label2(i).Caption Then MsgBox 請(qǐng) amp。HFFFFFF Then If Label2(4).Caption = Then = amp。Frmstsii窗體包含的主要控件及其屬性如下: 對(duì)象名屬性屬性值Combo1(0)TextCombolLabel1(0)Caption 添加Label1(1)Caption查詢Label1(2)Caption修改Label1(3)Caption刪除Label4Caption查詢中 請(qǐng)稍后…Label3Caption學(xué)籍信息列表MSFlexGrid1Row2Command1Caption添加Command2Caption取消其他屬性的設(shè)置與表中的類似。 .ColWidth(0) = 0 .ColWidth(1) = 1550 .ColWidth(2) = 1550 .ColWidth(3) = 1550 .ColWidth(4) = 1550 .ColWidth(5) = 1550 .Rows = 1 End With Text1(0) = GetRknoEnd SubPrivate Sub MSFlexGrid1_Click() Dim txtSQL As String If 0 Then Text3(0) = (, 0) Text3(1) = (, 1) Combo3(0).Clear Combo3(0).AddItem (, 2) Combo3(0).ListIndex = 0 txtSQL = select * from class_Form Set mrc = ExecuteSQL(txtSQL, MsgText) If = False Then With Combo3(0) Do While Not If mrc!class_NO .Text Then .AddItem Trim(mrc!class_NO) End If Loop End With End If Combo3(1).Clear Combo3(1).AddItem (, 3) Combo3(1).ListIndex = 0 Combo3(2).Clear Combo3(2).AddItem (, 4) Combo3(2).ListIndex = 0 Text3(2) = (, 5) Text4(0) = (, 0) Text4(1) = (, 1) Combo4(0).Clear Combo4(0).AddItem (, 2) Combo4(0).ListIndex = 0 Combo4(1).Clear Combo4(1).AddItem (, 3) Combo4(1).ListIndex = 0 Combo4(2).Clear Combo4(2).AddItem (, 4) Combo4(2).ListIndex = 0 Text4(2) = (, 5) End IfEnd Sub ,命名為“frmstsi”。Frmscoi窗口的界面設(shè)計(jì)示意圖如下.Frmscoi窗體包含的主要控件及其屬性如下: 對(duì)象名屬性屬性值Combo1(0)Caption學(xué)生班號(hào)LabelCaption考試期號(hào)Option1(0)Caption添加MSFlexGrid1BorderStyle1 –flexBorderSingle Picture1(0)DrawMode13 – Copy PenProgressBar1OrientationccOrientationHorizontalCommand1Caption添加Command2Caption取消其他控件以及屬性跟上面的表中的類似。 39。 amp。 Set mrc = ExecuteSQL(txtSQL, MsgText) If = False Then MsgBox 此用戶已經(jīng)存在!, vbOKOnly, 警告 Text1(0).SetFocus Exit Sub End If txtSQL = select * from user_Form Set mrc = ExecuteSQL(txtSQL, MsgText) (0) = Trim(Text1(0)) (1) = Trim(Text1(1)) (2) = Now For i = 0 To 2 Text1(i) = Next MsgBox 用戶添加成功!, vbOKOnly, 提示 ListappEnd Sub,命名為“frmprpi”。 Trim(Text1(0)) amp。Frmcusi窗體包含的控件及其屬性如下: 對(duì)象名屬性屬性值Label1Caption用戶列表Label2(0)Caption添加Label2(1)Caption修改Label2(2)Caption刪除Picture1 (0)IMEMode0 – No OperationList1List(List)Command1Caption添加Command2Caption取消Priv