这是一个学生信息管理系统。当点击“运行”时。点击“录入”菜单下的“开始”就会弹出一个对话框。说是实时错误‘424’,要求对象。这是怎么回事呢???急急!!!谢谢大家了!!问题出在粗体红色的那一行。
Private Sub Command1_Click()
stux = FreeFile
Open "c:\txt.txt" For Random As stux Len = Len(s)
.学号 = Text1.Text
.姓名 = Text2.Text
.性别 = Text3.Text
.政治面貌 = Text4.Text
.籍贯 = Text5.Text
.学院 = Text6.Text
.班级 = Text7.Text
.成绩 = Text8.Text
n = LOF(stux) / Len(s)
Put stux, n = 1, s
Close stux
Text1.Text = " "
Text2.Text = " "
Text3.Text = " "
Text4.Text = " "
Text5.Text = " "
Text6.Text = " "
Text7.Text = " "
Text8.Text = " "
Text1.SetFocus
End SubPrivate Sub Command2_Click()
Unload MeEnd SubPrivate Sub Form_Load()
With s
.学号 = Trim(Text1)
.姓名 = Trim(Text2)
.性别 = Trim(Text3)
.政治面貌 = Trim(Text4)
.籍贯 = Trim(Text5)
.学院 = Trim(Text6)
.班级 = Trim(Text7)
.成绩 = Trim(Text8)
End With
End Sub