Error using FileSystemObject

G

Guest

Hello all,
I am working on an application that use the FileSystemObject to check if
a file exists. This works fine on my machine, but when i moved the
application to the webserver and tried to access it from a different machine,
i get this error. Is there a workaround?

"ActiveX component cannot create object: scripting.FileSystemObject"

this is the part of the code, its an ASP page

<script language="vbscript">
dim fs
set fs=CreateObject("Scripting.FileSystemObject")
if(fs.FileExists("F:\inetsrv\wwwroot\scripts\file1.txt"))=true then
'code
else
'code
end if
-
-
</script>

Thanks
 
R

Ramesh, MS-MVP

Type in Start, Run:

regsvr32 scrrun.dll

If that does not help, reinstall Windows Script 5.6 in your system.

Windows Script 5.6 for Windows 98, Windows Millennium Edition, and Windows
NT 4.0:
http://www.microsoft.com/downloads/...F6-249C-4A72-BFCF-FC6AF26DC390&displaylang=en

Windows Script 5.6 for Windows XP and Windows 2000:
http://www.microsoft.com/downloads/...43-7E4B-4622-86EB-95A22B832CAA&displaylang=en

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Hello all,
I am working on an application that use the FileSystemObject to check if
a file exists. This works fine on my machine, but when i moved the
application to the webserver and tried to access it from a different
machine,
i get this error. Is there a workaround?

"ActiveX component cannot create object: scripting.FileSystemObject"

this is the part of the code, its an ASP page

<script language="vbscript">
dim fs
set fs=CreateObject("Scripting.FileSystemObject")
if(fs.FileExists("F:\inetsrv\wwwroot\scripts\file1.txt"))=true then
'code
else
'code
end if
-
-
</script>

Thanks
 
G

Guest

Thanks for the reply. But the page loads properly in my machine, i get the
error when accessing from other machines.
 
R

Ramesh, MS-MVP

Then that advice applies to the other machines ;)

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Thanks for the reply. But the page loads properly in my machine, i get the
error when accessing from other machines.
 
G

Guest

Thanks, but thats not possible. As i said its a web application, it will be
accessed by a lot many users.

Ramesh said:
Then that advice applies to the other machines ;)

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Thanks for the reply. But the page loads properly in my machine, i get the
error when accessing from other machines.

Ramesh said:
Type in Start, Run:

regsvr32 scrrun.dll

If that does not help, reinstall Windows Script 5.6 in your system.

Windows Script 5.6 for Windows 98, Windows Millennium Edition, and Windows
NT 4.0:
http://www.microsoft.com/downloads/...F6-249C-4A72-BFCF-FC6AF26DC390&displaylang=en

Windows Script 5.6 for Windows XP and Windows 2000:
http://www.microsoft.com/downloads/...43-7E4B-4622-86EB-95A22B832CAA&displaylang=en

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Hello all,
I am working on an application that use the FileSystemObject to check
if
a file exists. This works fine on my machine, but when i moved the
application to the webserver and tried to access it from a different
machine,
i get this error. Is there a workaround?

"ActiveX component cannot create object: scripting.FileSystemObject"

this is the part of the code, its an ASP page

<script language="vbscript">
dim fs
set fs=CreateObject("Scripting.FileSystemObject")
if(fs.FileExists("F:\inetsrv\wwwroot\scripts\file1.txt"))=true then
'code
else
'code
end if
-
-
</script>

Thanks
 
R

Ramesh, MS-MVP

Unfortunately, this is a client side problem afaik. Either scripting is not
installed properly or there are some problems initiating the
FileSystemObject in those machines.

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Thanks, but thats not possible. As i said its a web application, it will be
accessed by a lot many users.

Ramesh said:
Then that advice applies to the other machines ;)

--
Regards,

Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com


Thanks for the reply. But the page loads properly in my machine, i get the
error when accessing from other machines.

Ramesh said:
Type in Start, Run:

regsvr32 scrrun.dll

If that does not help, reinstall Windows Script 5.6 in your system.

Windows Script 5.6 for Windows 98, Windows Millennium Edition, and
Windows
NT 4.0:
http://www.microsoft.com/downloads/...F6-249C-4A72-BFCF-FC6AF26DC390&displaylang=en

Windows Script 5.6 for Windows XP and Windows 2000:
http://www.microsoft.com/downloads/...43-7E4B-4622-86EB-95A22B832CAA&displaylang=en
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top