December 18th, 2008, 05:42 PM
I used the code to upload the file it worked fine but i need to save the name of the file in a variable so i added the code like this
Set objUpload=New ShadowUpload
If objUpload.GetError<>"" Then
Response.Write("sorry, could not upload: "&objUpload.GetError)
Response.Write("found "&objUpload.FileCount&" files...<br />")
For x=0 To objUpload.FileCount-1
Response.write "getfilename:-" & getfilename & "<br/>"
Response.Write("file name: "&objUpload.File(x).FileName&"<br />")
Response.Write("file type: "&objUpload.File(x).ContentType&"<br />")
Response.Write("file size: "&objUpload.File(x).Size&"<br />")
Call objUpload.File(x).SaveToDisk(Server.MapPath("Uploadfiles"), "")
Response.Write("file saved successfully!")
but it came as blank
can u tell me what i am doing wrong
December 28th, 2012, 10:22 AM
I tried this code and works great. however I have one problem. The files get overwritten when the same files are uploaded. Instead i want to throw an error stating "File already exists in the folder". How to do it?
I tried fso.IfFileExists in the showuploader.asp but it does'nt work.
Thanks in advance