Forums

ASP

This topic is locked

File System Object And PureASP Upload

Posted 15 Aug 2002 17:10:11
1
has voted
15 Aug 2002 17:10:11 Brendan Collins posted:
I am using PureASP Upload 2.09 and have everything working perfectly. Now I need to somehow alter the code so that the images are placed into relevant folders based on Category.

When a new Category is created and an image is to be uploaded to this category I need to check if there is a folder for this category and if not then create one and place the image inside.

I have tried the following code on a blank page to create a folder and it works:

<%
Dim fso, f
Set fso = CreateObject("Scripting.FileSystemObject"
Set f = fso.CreateFolder("c:\NewFolderName"
CreateFolderDemo = f.Path
%>

So I have tried to incorporate this into the PureAsp Upload code and at the same time try to replace NewFolderName with the Category Folder name from the form to create a new folder for the category.

Any help is much appreciated!

Brendan



Reply to this topic