IIS ASP - GetDrive

This is Interesting: Free IT Magazines  
Home > Archive > IIS ASP > May 2007 > GetDrive





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author GetDrive
Jake G

2007-05-10, 7:19 pm

<%
Dim fs,d
Set fs=Server.CreateObject("Scripting.FileSystemObject")
Set d=fs.GetDrive("c:\")
Response.Write("Drive " & d & ":")
Response.Write("Total size in bytes: " & d.TotalSize)
set d=nothing
set fs=nothing
%>

Does anyone know how to get this to connect to a remote share? The IP
I want to connect to is 10.20.33.178. I mapped a drive from
10.20.33.90 to 10.20.33.178 called the K:\ drive.

I have tried both Set d=fs.GetDrive("k:\") and Set
d=fs.GetDrive("10.20.33.178") and Set d=fs.GetDrive("\
\10.20.33.178"). Nothing seems to work!!!!

Please help.

Thanks,
Jake G.

Bob Barrows [MVP]

2007-05-10, 7:19 pm

Jake G wrote:
> <%
> Dim fs,d
> Set fs=Server.CreateObject("Scripting.FileSystemObject")
> Set d=fs.GetDrive("c:\")
> Response.Write("Drive " & d & ":")
> Response.Write("Total size in bytes: " & d.TotalSize)
> set d=nothing
> set fs=nothing
> %>
>
> Does anyone know how to get this to connect to a remote share? The IP
> I want to connect to is 10.20.33.178. I mapped a drive from
> 10.20.33.90 to 10.20.33.178 called the K:\ drive.
>
> I have tried both Set d=fs.GetDrive("k:\") and Set
> d=fs.GetDrive("10.20.33.178") and Set d=fs.GetDrive("\
> \10.20.33.178"). Nothing seems to work!!!!
>


http://www.aspfaq.com/show.asp?id=2168

Mappings will not be recognized.

--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com