Filesystem object UNC Path Error 
Author Message
 Filesystem object UNC Path Error

I'm having a little trouble with the
Scripting.Filesystemobject ... Here's a segment
of code that I'm using.  I'm using VBScript on an
ASP page

<%
set objFS = server.createobject
("Scripting.Filesystemobject")

set objFolder = objFS.GetFolder
(\\computername\d\foldername)

for each file in objFolder.files
    response.write "NAME: " & file.name & "<BR>"
next
%>

I keep getting the following error.

Server object error 'ASP 0177 : 800a004c'

Server.CreateObject Failed

/default.asp, line 58

The operation completed successfully

Line 58 is the set objFolder = objFS.GetFolder
(\\computername\d\foldername)
line .... is there some special trick to get
GetFolder to work with UNC paths ???

any help would be VERY much appreciated

Thank you
Scott Vercuski

Sent via Deja.com http://www.*-*-*.com/
Before you buy.



Mon, 14 Apr 2003 22:08:24 GMT  
 Filesystem object UNC Path Error

Quote:

> I'm having a little trouble with the
> Scripting.Filesystemobject ... Here's a segment
> of code that I'm using.  I'm using VBScript on an
> ASP page

> <%
> set objFS = server.createobject
> ("Scripting.Filesystemobject")

> set objFolder = objFS.GetFolder
> (\\computername\d\foldername)

> for each file in objFolder.files
>     response.write "NAME: " & file.name & "<BR>"
> next
> %>

> I keep getting the following error.

> Server object error 'ASP 0177 : 800a004c'

> Server.CreateObject Failed

> /default.asp, line 58

> The operation completed successfully

> Line 58 is the set objFolder = objFS.GetFolder
> (\\computername\d\foldername)
> line .... is there some special trick to get
> GetFolder to work with UNC paths ???

> any help would be VERY much appreciated

> Thank you
> Scott Vercuski


Try passing a string, e.g.  ...

  set objFolder = objFS.GetFolder("\\computername\d\foldername")

Tom Lavedas
-----------
http://www.pressroom.com/~tglbatch/



Mon, 14 Apr 2003 23:54:54 GMT  
 Filesystem object UNC Path Error

Q207671 - HOWTO: Accessing Network Files from IIS Applications
http://support.microsoft.com/support/kb/articles/Q207/6/71.ASP

--
Michael Harris
Microsoft.MVP.Scripting
--

Quote:

> I'm having a little trouble with the
> Scripting.Filesystemobject ... Here's a segment
> of code that I'm using.  I'm using VBScript on an
> ASP page

> <%
> set objFS = server.createobject
> ("Scripting.Filesystemobject")

> set objFolder = objFS.GetFolder
> (\\computername\d\foldername)

> for each file in objFolder.files
>     response.write "NAME: " & file.name & "<BR>"
> next
> %>

> I keep getting the following error.

> Server object error 'ASP 0177 : 800a004c'

> Server.CreateObject Failed

> /default.asp, line 58

> The operation completed successfully

> Line 58 is the set objFolder = objFS.GetFolder
> (\\computername\d\foldername)
> line .... is there some special trick to get
> GetFolder to work with UNC paths ???

> any help would be VERY much appreciated

> Thank you
> Scott Vercuski

> Sent via Deja.com http://www.deja.com/
> Before you buy.



Tue, 15 Apr 2003 10:14:55 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. FileSystem problem with UNC paths

2. FileSystem Object Network Path Error

3. filesystem object and UNC?

4. CreateTextFile Error with UNC path

5. Converting logical paths to UNC paths

6. Converting logical paths to UNC paths

7. Converting local path to UNC path?

8. Local path vs UNC Path

9. Help converting UNC paths to physical paths.

10. How transform path into unc-path ?

11. How to convert local path to UNC-path?

12. How to convert local path to UNC-path?

 

 
Powered by phpBB® Forum Software