作家
登录

用asp实现读取文件的最后一行的代码

作者: 来源:www.28hudong.com 2013-03-30 08:19:24 阅读 我要评论

复制代码 代码如下:function FSOlastline(filename) dim fso,f,temparray,tempcnt set fso = server.CreateObject("scripting.filesystemobject") if not fso.fileExists(server.mappath(filename)) then exit function set f = fso.opentextfile(server.mappath(filename),1) if not f.AtEndofStream then tempcnt = f.readall f.close set f = nothing temparray = split(tempcnt,chr(13)&chr(10)) FSOlastline = temparray(ubound(temparray)) end if end function

  推荐阅读

  ASP Cookies操作的详细介绍与实例代码

Cookie是一种发送到客户浏览器的文本串句柄,并保存在客户机硬盘上,可以用来在某个Web站点会话之间持久地保持数据。Request和Response对象都有一组Cookie。Request.cookie集合是一系列Cookie,从客户端与HTTP Req>>>详细阅读


本文标题:用asp实现读取文件的最后一行的代码

地址:http://www.17bianji.com/kaifa2/ASP/31957.html

关键词: 探索发现

乐购科技部分新闻及文章转载自互联网,供读者交流和学习,若有涉及作者版权等问题请及时与我们联系,以便更正、删除或按规定办理。感谢所有提供资讯的网站,欢迎各类媒体与乐购科技进行文章共享合作。

网友点评
自媒体专栏

评论

热度

精彩导读
栏目ID=71的表不存在(操作类型=0)