Image

Imagegubaby wrote in Imagewebdev

ASP question

I want to generate a text file with some text and I have the following code.

Dim createfile, fileobject
set fileobject = Server.CreateObject("Scripting.FileSystemObject")
if not fileobject.FileExists(Server.MapPath("layne.txt")) then
set createfile = fileobject.CreateTextFile(Server.MapPath("layne.txt"), False)
createfile.Write("Image")
'createfile.WriteLine("there")
createfile.Close
set createfile = nothing
end if

set fileobject = nothing


The error is on the double quotes in line 5:

createfile.Write("Image")

Can someone help me out?