![]() |
#2
VB丶小宇2014-10-29 10:06
|
在标准模块输入如下
Type record
name As String * 10
unit As String * 15
age As Integer
salary As Single
End Type
在窗体模块输入如下
Dim a As record(在通用声明)
Private Sub Form_Click()
Open "f:\abc.dat" For Random As #1 Len = Len(a)
a.name = InputBox("姓名")
a.unit = InputBox("职位")
a.age = InputBox("年龄")
a.salary = InputBox("工资")
Put #1, , a
Get #1, 1, a
Print a.name, a.unit, a.age, a.salary
End Sub
为什么 在窗体上显示的信息不全 没有最后一个