Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Files Upload

Status
Not open for further replies.

Rachel80

Programmer
May 25, 2000
63
GB
Hi,

1) I'm trying to do simple file(images & html) upload function.. saw several website for the upload file tutorial and found different versions (some very long codings..). I wish to use non-proprietary file uploading methods.

2) when i get the path from the <input type=&quot;file&quot;>, how can i get the file name only? i want to substring the pathname, getting only the file name and insert into Access table as text field. The file will be uploaded under my directory's subfolder.

Pls help, thanx!
Rach ;-)
 
Perhaps you could use the FileSystemObject.



Dim FSO 'FileSystemObject
Dim FLDR 'FolderObject
Dim FCO 'FileCollectionObject
Dim FO 'FileObject

Set FSO = Server.CreateObject(&quot;Scripting.FileSystemObject&quot;)
Set FLDR = FSO.GetFolder(The Path To Your Folder)
Set FCO = FLDR.Files

For Each FO In FCO
Response.Write(FLDR.Path) 'Prints Path
Response.Write(FO.Name) 'Prints File Name
Next FO
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top