Dim Classprint As New OpenRs' definition of print record set
Dim xlApp As New Excel. Application
Dim sendsql As String
Private Sub gridcs initialized () 'demand on the grid
On Error GoTo finish
The Select Case Grid1. Cell (hang, 7). The Text
Case "from Monday to Friday"
Grid2. Cols=5 + 1
* nknumberGrid3. Cols=5 + 1
* nknumberCase "from Monday to Saturday,"
Grid2. Cols=6 * nknumber + 1
Grid3. Cols=6 * nknumber + 1
Case "from Monday to Sunday
"Grid2. Cols=7 * nknumber + 1
Grid3. Cols=7 * nknumber + 1
End the Select 'listed below are the corresponding teachers and class resources
Grid2. Range (1, 1, Grid2 Rows 1, Grid2. The Cols - 1). The ClearText
Grid3. Range (1, 1, Grid3 Rows 1, Grid3. The Cols - 1). The ClearText
Set kc2=CNN. Execute (" select occupy the from to take up the where teachers name='" & amp; Grid1. Cell (hang, 5). The Text & amp; "'")
For I=1 To Grid2. Cols - 1
Grid2. Cell (1, I). The Text=Mid (kc2. Fields (0), I, 1)
Next
Grid3. Range (1, 1, Grid3 Rows 1, Grid3. The Cols - 1). The Alignment=cellCenterCenter
The Set kc2=CNN. Execute (" select occupy the from course takes up where the class='" & amp; XPCombo1. Text & amp; "'")
For I=1 To Grid3. Cols - 1
Grid3. Cell (1, I). The Text=Mid (kc2. Fields (0), I, 1)
Next
The Exit Sub
Finish:
MsgBox Err. The Description
End Sub
Private Sub grid4hq () 'access between the teacher and the class course point
On Error GoTo finish
Grid4. Rows=1
Dim m As Integer
For I=1 To Grid2. Cols - 1 Step n 'through the contrast between the teacher and the class can be summarizing arranging points
If Grid2. Cell (1, I). The Text="0" Then
If Grid3. Cell (1, I). The Text="0" Then
Grid4. Rows=Grid4. Rows + 1
Grid4. Cell (Grid4. Rows - 1, 1). The Text=I
End the If
End the If
Next
The Exit Sub
Finish:
MsgBox Err. The Description
End Sub
Private Sub asPopup1_Click (Cancel As Boolean)
Kctable="login"
Form6. Caption="user management"
Form6. Show 1
End Sub
Private Sub asPopup10_Click (Cancel As Boolean)
Kctable="class name"
Form6. Caption="classroom management"
Form6. Show 1
End Sub
Private Sub asPopup2_Click (Cancel As Boolean)
Kctable="teaching period"
Form5. Caption="teaching time set"
Form5. Show 1
End Sub
Private Sub asPopup3_Click (Cancel As Boolean)
End
End Sub
Private Sub asPopup4_Click (Cancel As Boolean)
Kctable="of course"
Form5. Caption="curriculum management"
Form5. Show 1
End Sub
Private Sub asPopup5_Click (Cancel As Boolean) 'here are some to generate an error data reduction
Dim vyes As String
Vyes=MsgBox (" when the system is arranging mistakes to completely restore operations, sure?" , vbQuestion + vbYesNo, "tip")
If vyes=vbYes Then
The Set kc2=CNN. The Execute (" update takes up the Set to take up='000000000000000000000000000000000000000000' ")
The Set kc2=CNN. The Execute (" update course takes up the Set to take up='000000000000000000000000000000000000000000' ")
End the If
End Sub
...
This is part of the code
There are a few other parts
Help students to do graduate design
Dim I, n As Integer
Private Declare Function GetKeyState Lib "user32" _
(ByVal nVirtKey As Long) As an Integer
Private Sub Form_Load ()
Grid1. SetRegisterInformation CNwinndy ""," W] vyY - nonvk -u \ nty - Zbl_e - ` HMS ^ "' register
With Grid1
. AllowUserResizing=True
. DisplayFocusRect=False
. ExtendLastCol=True
The Appearance=Flat
. FixedRowColStyle=Flat
. ScrollBarStyle=Flat
. DefaultFont. Name="Tahoma"
. DefaultFont. Size=8
BackColorFixed=RGB (90, 158, 214)
BackColorFixedSel=RGB (110, 180, 230)
BackColorBkg=RGB (90, 158, 214)
BackColorScrollBar=RGB (231, 235, 247)
BackColor1=RGB (231, 235, 247)
BackColor2=RGB (239, 243, 255)
GridColor=RGB (148, 190, 231)
The Column (0). The Width=0
The Column (1). The Width=150
The Column (2). The Width=100
The Column (3). The Width=100
The Column (3). Locked=True
End With
MsgBox "because one is using the class here some of the resources, using modify, and delete is likely to cause unnecessary loss!" VbInformation, "hint"
Call callmain
End Sub
Private Sub callmain ()
Kcsave=False
Kcedit=True
Kcdel=True
The Set kc1=CNN. Execute (" select * from "& amp; Kctable)
The Select Case kctable
Case "of course", "teaching period"
Grid1. Rows=1 'clear all records
I=2
End the Select
Grid1. Cols=I + 1 'must be + 1, because in fact is 4 line, but the first line is hidden
For I=0 To I - 1 'display the data of field name
Grid1. Cell (0, I + 1). The Text=kc1. Fields (I). The Name 'reads the field Name in table
Next
N=I
I=1
EOF
the Do While Not kc1.Grid1. Rows=Grid1. Rows + 1
For j=1 To n 'column set read
If kc1. Fields (j - 1) Null=Null Then 'processing
Grid1. Cell (I, j) Text=""
The Else
Grid1. Cell (I, j) Text=kc1. Fields (j - 1)
End the If
Next
I=I + 1
Kc1. MoveNext 'read the next record
Loop
Grid1. Column (1). Locked=True
End Sub
Private Sub Form_Unload (Cancel As Integer)
Call XPButton5_Click
End Sub
Private Sub Grid1_MouseUp (Button As an Integer, Shift the As an Integer, As Single X, Y As Single)
If the Button=2 Then
PopupMenu cz
End the If
End Sub
Private Sub Grid1_RowColChange (ByVal Row As Long, ByVal Col As Long)
Hang=Row
End Sub
Private Sub Grid1_Validate (Cancel As Boolean) 'set the TAB key to switch
nullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnull