📄 form2.frm
字号:
VERSION 5.00
Begin VB.Form Form2
BorderStyle = 1 'Fixed Single
Caption = "学生登陆——利军学生成绩管理系统V1.0"
ClientHeight = 6855
ClientLeft = 3045
ClientTop = 2310
ClientWidth = 8655
Icon = "Form2.frx":0000
LinkTopic = "Form2"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 6855
ScaleWidth = 8655
Begin VB.CommandButton Command1
BackColor = &H000000C0&
Caption = "退出登陆"
Height = 375
Left = 2880
TabIndex = 8
Top = 5760
Width = 2895
End
Begin VB.CommandButton xgm
BackColor = &H80000009&
Caption = "修改"
Height = 375
Left = 6600
TabIndex = 1
Top = 960
UseMaskColor = -1 'True
Width = 615
End
Begin VB.CommandButton xgd
Caption = "修改"
Height = 375
Left = 6600
TabIndex = 3
Top = 2400
Width = 615
End
Begin VB.Frame Frame1
Caption = "个人信息"
Height = 2415
Left = 1320
TabIndex = 20
Top = 600
Width = 6015
Begin VB.TextBox xh
Enabled = 0 'False
Height = 375
Left = 960
TabIndex = 25
Text = "暂无记录"
Top = 360
Width = 1455
End
Begin VB.TextBox mm
Height = 375
Left = 3840
TabIndex = 0
Top = 360
Width = 1455
End
Begin VB.TextBox xm
Enabled = 0 'False
Height = 375
Left = 960
TabIndex = 24
Top = 1080
Width = 1455
End
Begin VB.TextBox sr
Enabled = 0 'False
Height = 375
Left = 960
TabIndex = 23
Top = 1800
Width = 1455
End
Begin VB.TextBox dh
Height = 375
Left = 3840
TabIndex = 2
Top = 1800
Width = 1455
End
Begin VB.OptionButton nan
Caption = "男"
Enabled = 0 'False
Height = 255
Left = 4080
TabIndex = 22
Top = 1080
Value = -1 'True
Width = 495
End
Begin VB.OptionButton nv
Caption = "女"
Enabled = 0 'False
Height = 255
Left = 4800
TabIndex = 21
Top = 1080
Width = 495
End
Begin VB.Label Label1
Caption = "学号:"
Height = 255
Left = 360
TabIndex = 31
Top = 360
Width = 615
End
Begin VB.Label Label2
Caption = "密码:"
Height = 255
Left = 3240
TabIndex = 30
Top = 360
Width = 615
End
Begin VB.Label Label3
Caption = "姓名:"
Height = 255
Left = 360
TabIndex = 29
Top = 1080
Width = 615
End
Begin VB.Label Label4
Caption = "性别:"
Height = 255
Left = 3240
TabIndex = 28
Top = 1080
Width = 615
End
Begin VB.Label Label5
Caption = "生日:"
Height = 255
Left = 360
TabIndex = 27
Top = 1800
Width = 615
End
Begin VB.Label Label6
Caption = "电话:"
Height = 255
Left = 3240
TabIndex = 26
Top = 1800
Width = 615
End
End
Begin VB.Frame Frame2
Caption = "学习成绩"
Height = 2175
Left = 1320
TabIndex = 9
Top = 3360
Width = 6015
Begin VB.CommandButton pjs
Caption = "计算"
Height = 375
Left = 5280
TabIndex = 7
Top = 1560
Width = 615
End
Begin VB.TextBox gs
Enabled = 0 'False
Height = 375
Left = 960
TabIndex = 13
Top = 360
Width = 1455
End
Begin VB.TextBox yy
Enabled = 0 'False
Height = 375
Left = 3840
TabIndex = 12
Top = 360
Width = 1455
End
Begin VB.TextBox wl
Enabled = 0 'False
Height = 375
Left = 960
TabIndex = 11
Top = 960
Width = 1455
End
Begin VB.TextBox hx
Enabled = 0 'False
Height = 375
Left = 3840
TabIndex = 10
Top = 960
Width = 1455
End
Begin VB.TextBox zf
Height = 375
Left = 960
TabIndex = 4
Top = 1560
Width = 1455
End
Begin VB.TextBox pm
Height = 375
Left = 3840
TabIndex = 6
Top = 1560
Width = 1455
End
Begin VB.CommandButton zjs
Caption = "计算"
Height = 375
Left = 2400
TabIndex = 5
Top = 1560
Width = 615
End
Begin VB.Label Label7
Caption = "高数:"
Height = 255
Left = 360
TabIndex = 19
Top = 360
Width = 615
End
Begin VB.Label Label8
Caption = "英语:"
Height = 255
Left = 3240
TabIndex = 18
Top = 360
Width = 615
End
Begin VB.Label Label9
Caption = "物理:"
Height = 255
Left = 360
TabIndex = 17
Top = 960
Width = 615
End
Begin VB.Label Label10
Caption = "化学:"
Height = 255
Left = 3240
TabIndex = 16
Top = 960
Width = 615
End
Begin VB.Label Label11
Caption = "总分:"
Height = 255
Left = 360
TabIndex = 15
Top = 1560
Width = 615
End
Begin VB.Label Label12
Caption = "排名:"
Height = 255
Left = 3240
TabIndex = 14
Top = 1560
Width = 615
End
End
End
Attribute VB_Name = "Form2"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim student As studtype
Dim reno As Integer
Dim book As Integer
Public Function du(readn As Integer)
Get #1, readn, student
With student
xh = Trim(.snum)
mm = Trim(.pass)
xm = Trim(.name)
sr = Trim(.birth)
dh = Trim(.tel)
gs = .gaoshu
yy = .yingyu
wl = .wuli
hx = .huaxue
zf = .zongfen
pm = .paiming
If .sex = "1" Then
nan.Value = True
Else
nv.Value = True
End If
End With
Close #1
End Function
Public Function xie(writen As Integer)
With student
.pass = mm
.tel = dh
End With
Put #1, writen, student
Close #1
End Function
Public Sub dak()
Dim mpath As String
mpath = App.Path
If Right(mpath, 1) <> "\" Then mpath = mpath + "\"
mpath = mpath + "chengji.txt"
Open mpath For Random As #1 Len = Len(student)
reno = LOF(1) / Len(student)
End Sub
Private Sub Command1_Click()
End
End Sub
Private Sub Form_Load()
Call dak
du (Val(frmLogin.iz.Caption))
End Sub
Private Sub Form_Unload(Cancel As Integer)
End
End Sub
Private Sub pjs_Click()
pm = (Val(gs) + Val(yy) + Val(wl) + Val(hx)) / 4
End Sub
Private Sub xgd_Click()
Call dak
xie (Val(frmLogin.iz.Caption))
End Sub
Private Sub xgm_Click()
Call dak
xie (Val(frmLogin.iz.Caption))
End Sub
Private Sub zjs_Click()
zf = Val(gs) + Val(yy) + Val(wl) + Val(hx)
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -