John K.
03-24-2000, 07:45 PM
I keep getting the error "Object variable not set" when I
run this code in my ASP page.
Set fs = server.CreateObject("Scripting.FileSystemObject")
Set folder = fs.GetFolder(sdir)
Set fc = folder.Files
ReDim sFiler(fc.count)
For Each sfile in fc
if readfile(sfile.path, stext, nlen) = 1 then <-- Error occurs on the line
nAntal = nAntal + 1
sFiler(nAntal) = sfile
end if
Next
What could be wrong?
Please help.
run this code in my ASP page.
Set fs = server.CreateObject("Scripting.FileSystemObject")
Set folder = fs.GetFolder(sdir)
Set fc = folder.Files
ReDim sFiler(fc.count)
For Each sfile in fc
if readfile(sfile.path, stext, nlen) = 1 then <-- Error occurs on the line
nAntal = nAntal + 1
sFiler(nAntal) = sfile
end if
Next
What could be wrong?
Please help.