[thelist] Creating Directories in ASP
Aaron Johnson
lists at cephas.net
Fri Feb 7 09:42:01 CST 2003
Hi Frank,
> I am working on an application where I want to have the user sign
> up for an account, and then have it create a directory on the
> server automatically for them and then transfer files into that
> directory using ASP. Can anyone help point me in the right
> direction?
-- here's a quick function that'll create a directory for you:
Sub CreateFolder(strFolderPath)
Dim objFSO
'create an FSO
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
'make sure folder doesn't already exist
if NOT objFSO.FolderExists(strFolderPath) then
objFSO.CreateFolder(strFolderPath)
end if
Set objFSO = Nothing
End Sub
where strFolderPath is the physical path to the directory you'd like created
(ie: c:\hosts\mysite.com\wwwroot\aaron\)
AJ
Aaron Johnson
http://cephas.net/blog/
ajohnson at cephas.net
More information about the thelist
mailing list