vb 代码区别 Open "temp.txt" For Input As #1 Line Input #1,s Close #1 --Open "temp.txt" For Input As #1Line Input #1,sClose #1与下面的代码区别(少了个Line)Open "temp.txt" For Input As #1Input #1,sClose #1

来源:学生作业帮助网 编辑:作业帮 时间:2024/11/01 06:47:11

vb 代码区别 Open "temp.txt" For Input As #1 Line Input #1,s Close #1 --Open "temp.txt" For Input As #1Line Input #1,sClose #1与下面的代码区别(少了个Line)Open "temp.txt" For Input As #1Input #1,sClose #1
vb 代码区别 Open "temp.txt" For Input As #1 Line Input #1,s Close #1 --
Open "temp.txt" For Input As #1
Line Input #1,s
Close #1
与下面的代码区别(少了个Line)
Open "temp.txt" For Input As #1
Input #1,s
Close #1

vb 代码区别 Open "temp.txt" For Input As #1 Line Input #1,s Close #1 --Open "temp.txt" For Input As #1Line Input #1,sClose #1与下面的代码区别(少了个Line)Open "temp.txt" For Input As #1Input #1,sClose #1
1) Input #文件号,变量列表
   作用:将从文件中读出的数据分别赋给指定的变量.
注意:与Write #配套才可以准确地读出.
  2)Line Input #文件号,字符串变量
    用于从文件中读出一行数据,并将读出的数据赋给指定的字符串变量,读出的数据中不包含回车符和换行符,可与Print #配套用.