1

我在 BBx 中有一个超过 30 年的程序,需要在它自己的数据库之外读取一些内容。实际上它必须是非常简单的东西

txt$ = 读取 (message.txt) 打印 txt$

但是没有任何可用的文档。所以我的问题是:如何将纯 txt 文件读入 BBx4

4

1 回答 1

0

简单地打开文件并使用 READ RECORD 读取它

open (1,err=linenr) "message.txt"    
read record (1,siz=1,end=linenr) txt$

在通道 1 上打开, linenr=line to go when there is an error *siz=1 reads 1 character siz=100 reads 100 etc. end 当检测到文件结尾时要去哪里。

于 2016-04-25T19:09:03.673 回答