Private Sub Command1_Click()
Dim intfnum As Integer
Dim intctr As Integer
Dim strname(4) As String * 8
Dim strage(4) As String * 8
Dim strcolor(4) As String * 8
For intctr = 1 To 4
strname(intctr) = InputBox("名字")
strage(intctr) = InputBox("年龄")
strcolor(intctr) = InputBox("颜色")
Next intctr
intfnum = FreeFile
Open "e:\信息.txt" For Random As intfnum Len = 8
For intctr = 1 To 4
Put #strname(intctr), strage(intctr), strcolor(intctr)
Next intctr
Close #intfnum
End Sub
查了半天不知道原因,请教各位前辈。