files system object/ textstream

Results 1 to 2 of 2

Thread: files system object/ textstream

  1. #1
    sv Guest

    Default files system object/ textstream

    I keep getting an error that says file not found when<BR>i try to retrieve a file using the file systems object.<BR>I know my path is right and I can&#039;t figure out what&#039;s<BR>wrong with it. Do I need to install something else on the<BR>server?<BR><BR><BR>&#039;The directory of all the pictures... <BR><BR>Const mypath="/Picture" <BR><BR>Set filesystem = Server.CreateObject("Scripting.FileSystemObject") <BR><BR>set File= FileSystem.GetFile(Server.MapPath(mypath)) <BR><BR>if filesystem.FileExists("picture00.txt") then <BR><BR>set TextStream = FileSystem.OpenTextFile("picture00.txt", 1) <BR><BR>do until not TextStream.AtEndOfStream <BR><BR>Response.Write TextStream.ReadLine & " "<BR><BR> loop<BR><BR> TextStream.close<BR><BR> else<BR> Response.write "File not there" <BR><BR>end if <BR>set filesystem=nothing

  2. #2
    Join Date
    Dec 1969

    Default RE: files system object/ textstream

    set TextStream = FileSystem.OpenTextFile(mypath & "/picture00.txt", 1) <BR><BR>Try that<BR>Jason<BR><BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts