Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

fso problem

Status
Not open for further replies.

Bignewbie

Programmer
Feb 22, 2001
351
PH
what is wrong with this script:

<%

directoryname=&quot;C:\home\sites\site4\priv\&quot;
Set fso = CreateObject(&quot;Scripting.FileSystemObject&quot;)
set mainfolder=fso.GetFolder(directoryname)
Set filecollection = mainfolder.Files
For Each file In filecollection
Response.Write file.Name & &quot;<br>&quot;
Next


%>


everytime I run this, it crashes my IIS. My IIS is on port 8080. Does this matter? Please help me!


biggie




The Man of Tomorrow is forged by his battles today.
 
If that isn't the issue, then define crashes:
IIS freezes up - dllhost is at 99% indefinately and you can't stop IIS
IIS has magically stopped by itself
The web page shopws an error message
etc

-T

01000111 01101111 01110100 00100000 01000011 01101111 01100110 01100110 01100101 01100101 00111111
The never-completed website:
 
GaryC is right, norton made my IIS not to respond. Does Norton's script blocking really blocks scripts done on the client's computer or does it just protect the server?


biggie



The Man of Tomorrow is forged by his battles today.
 
ASP is server-side not client-side. What was happening is that the Norton on your sertver was blocking the FSO object's attempts to access the server's file system. Apparently there isn't a timeout in the file system object to handle not being able to access the file system so it just hangs indefinately. IIS hangs because the FSO object is an external object (you can force this to occur with the regular expression object also).

-T

01000111 01101111 01110100 00100000 01000011 01101111 01100110 01100110 01100101 01100101 00111111
The never-completed website:
 
Hi,

I'm new to ASP. I'm working on the File System Object. My code reads-

<%
dim myFso

set myFso = server.createobject(&quot;Scripting.FileSystemObject&quot;)

if isobject(myFso) then

for each cdrive in myFso.Drives

response.write cdrive.driveletter

next

end if


%>

I've already disabled NAV script blocking. All I get is a blank page.

mark
 
hijacking it considered bad form mark. but I see you already started a thread!

___________________________________________________________________
onpnt2.gif

The answer to your ??'s may be closer then you think.
Check out Tek-Tips knowledge bank by clicking the FAQ link at the top of the page
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top