大肚子减肥帖:今天学习ASP的filesystemobject的forappending有读的功能吗?

来源:百度文库 编辑:神马品牌网 时间:2024/05/04 08:47:36
ASP的filesystemobject关于writeline和readline的困惑
为什么我用writeline写入,然后用readline读取出现错误,forappending能读吗?程序如下
<%
a=123456789
set fso=server.createobject("scripting.filesystemobject")
filepath=server.mappath("book.txt")
const forappending=8
set f=fso.opentextfile(filepath,forappending)
f.writeline a
%>
我若在后面加
s=f.radline
response.write s
出现错误,后来发现把forappending取消了,才能读取,当然writeline也不能要了,我困惑的是forappending是只写还是可读可写,若是可读可写,我加上最后的几句应该能显示
是s=f.readline
response.write s
而不是s=f.radline
response.write s
在baidu写错了,但问题不是这

路过

前面已经有f=123456789
程序不认识f.radline
s=f.radline
response.write s
这两句话不能识别