假定在工程文件中有一个标准模块,其中定义了如下记录类型:Type BooksName As String*10TelNuin As String*20End Type要求在执行事件过程Command1_Click时,在顺序文件Person.txt中写入一条记录。将以下程序补充完整。Private Sub Command1_Clickk()DimB As Booksopen"c:\person.txt"For output As 1B.Name=InputBox("请输入姓名")B.TelNum=Input

题目

假定在工程文件中有一个标准模块,其中定义了如下记录类型:Type Books

Name As String*10

TelNuin As String*20

End Type

要求在执行事件过程Command1_Click时,在顺序文件Person.txt中写入一条记录。将以下程序补充完整。

Private Sub Command1_Clickk()

DimB As Books

open"c:\person.txt"For output As 1

B.Name=InputBox("请输入姓名")

B.TelNum=InputBox("请输入电话号码")

write 1,______

close 1

End Sub


相似考题