#16
  1. No Profile Picture
    Contributing User
    ASP Explorer (0 - 99 posts)

    Join Date
    Dec 2006
    Posts
    46
    Rep Power
    12
    Hey Shadow Wizard, im kind of a beginner and just happend to come across the sample, i love your uploader. But when i am testing the code i get an error stating :
    Microsoft VBScript runtime error '800a004c'

    Path not found

    /flextemp2/ShadowUploader.asp, line 283


    I bascailly just want to upload .doc files to a database i've created that is located on the server. Is there anything else i need to change with the code to make sure it goes to the server and to the database? location is stuartabrams.com/flextemp2/apply2.asp
    Thanks N Advance
  2. #17
  3. Moderator From Beyond
    ASP Mastermind (5000+ posts)

    Join Date
    Sep 2004
    Location
    Israel
    Posts
    31,135
    Rep Power
    2926
    hi and welcome to the forum!

    sorry, but my uploader does not support uploading into database.
    it can only save the uploaded files as files on the server disk.
    you can grab those files and write their contents to the database
    later in the code though so if you prefer to stick with my uploader
    I can guide you - first step is to save the uploaded file.
    for this, please post your code where you call SaveToDisk method
    and I'll see what you're doing wrong.
  4. #18
  5. Moderator From Beyond
    ASP Mastermind (5000+ posts)

    Join Date
    Sep 2004
    Location
    Israel
    Posts
    31,135
    Rep Power
    2926
    thread has been cleaned again, see the first post for the
    list of related threads where the posts have been moved.
  6. #19
  7. Expert Learner
    ASP Skiller (1500 - 1999 posts)

    Join Date
    Feb 2005
    Location
    Wisconsin
    Posts
    1,909
    Rep Power
    101
    It would be possible to get it to work though, if it was modified to insert into the db as a BLOB type...wouldn't it? lol
  8. #20
  9. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    May 2006
    Posts
    5
    Rep Power
    0
    how do i stop ot from adding "uploads" to the name of the file?
  10. #21
  11. Moderator From Beyond
    ASP Mastermind (5000+ posts)

    Join Date
    Sep 2004
    Location
    Israel
    Posts
    31,135
    Rep Power
    2926
    it's not adding anything to the name of the file.
    by default my script will save the file using its original name
    and I've added the option to decide the name yourself.

    "uploads" is the name of the folder in which the file
    is being saved and you can change this to whatever folder
    name you want. you can also save the file to the same folder
    as the upload script, saving the files to seperate folder is not
    must be.
  12. #22
  13. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    May 2006
    Posts
    5
    Rep Power
    0
    Originally Posted by Shadow Wizard
    it's not adding anything to the name of the file.
    by default my script will save the file using its original name
    and I've added the option to decide the name yourself.

    "uploads" is the name of the folder in which the file
    is being saved and you can change this to whatever folder
    name you want. you can also save the file to the same folder
    as the upload script, saving the files to seperate folder is not
    must be.
    well for some reason it adds "uploads" to the beging of the file name. An example is if i upload a file called test.exe it uploads it to the server as uploadstest.exe
  14. #23
  15. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    May 2006
    Posts
    5
    Rep Power
    0
    i looked again and it looks like since there was no folder called uploads it added upload to the beging of the file name. How do i set it not to use a folder then?
  16. #24
  17. Moderator From Beyond
    ASP Mastermind (5000+ posts)

    Join Date
    Sep 2004
    Location
    Israel
    Posts
    31,135
    Rep Power
    2926
    Originally Posted by rwssoccer1
    i looked again and it looks like since there was no folder called uploads it added upload to the beging of the file name. How do i set it not to use a folder then?
    to upload the file to the same location of the upload script using
    the original file name, change this line:
    Code:
    Call objUpload.File(x).SaveToDisk(Server.MapPath("Uploads"), "")
    to this:
    Code:
    Call objUpload.File(x).SaveToDisk(Server.MapPath("."), "")
    the "." specify "current folder".
  18. #25
  19. No Profile Picture
    Contributing User
    ASP Discoverer (100 - 499 posts)

    Join Date
    May 2007
    Posts
    217
    Rep Power
    13
    Worked
  20. #26
  21. No Profile Picture
    Registered User
    ASP Explorer (0 - 99 posts)

    Join Date
    Mar 2006
    Posts
    11
    Rep Power
    0
    Hi Bud amazing tutorial. Is there anyway you can upload the files to a spefic folder the uploads.

    For example say if the person with user_name = A uploads a file and it is stored into a folder within upload called A.

    in example I would be doing

    sqlText="select * from members where first_name='"&first_name &"'"
    set userSet = outpostDB.Execute(sqlText)


    to get users details, but how would I manipulate the following line so that I can save it to a folder already created on the server called A or username??

    Call objUpload.File(x).SaveToDisk(Server.MapPath("../userSet("username")"),"")

    not sure any help would be great thank you
  22. #27
  23. Moderator From Beyond
    ASP Mastermind (5000+ posts)

    Join Date
    Sep 2004
    Location
    Israel
    Posts
    31,135
    Rep Power
    2926
    the correct syntax is this:
    Code:
    Call objUpload.File(x).SaveToDisk(Server.MapPath("../" & userSet("username")), "")
  24. #28
  25. No Profile Picture
    Contributing User
    ASP Discoverer (100 - 499 posts)

    Join Date
    Jun 2007
    Posts
    122
    Rep Power
    12
    Hi Shadow,

    Code is brillant, quick question for you, i jus want to know when you click on a file to upload, it doesn't like uploading a file with a space in its name?
  26. #29
  27. Moderator From Beyond
    ASP Mastermind (5000+ posts)

    Join Date
    Sep 2004
    Location
    Israel
    Posts
    31,135
    Rep Power
    2926
    Originally Posted by davidrocastle
    Hi Shadow,

    Code is brillant, quick question for you, i jus want to know when you click on a file to upload, it doesn't like uploading a file with a space in its name?
    checked this now myself and it's working just fine.
    this means you did something wrong, please post
    your code and full error message.
  28. #30
  29. No Profile Picture
    Contributing User
    ASP Explorer (0 - 99 posts)

    Join Date
    Jul 2007
    Posts
    43
    Rep Power
    12
    Hey, I'm having a little trouble getting your script to work.

    I uploaded the file from the zip package to my webpage, and used INCLUDE FILE to call it from another ASP page. Unfortunently when I go to the page it simply says "Service Unavailable"

    Do you guys think this has something to do with my host? I am using netfirms, and I know I bought the package with ASP.NET. If you go to www.netfirms.com, I bought the big package at the top that says "We've added Windows ASP.NET".

    Heres what I'm talking about www.one19music.net/ShadowUploader.asp ... thats the exact file from the first post. Does anyone have any ideas??

Similar Threads

  1. Upload Script with HTTPget
    By comix2000 in forum ASP Development
    Replies: 1
    Last Post: January 20th, 2005, 06:50 PM
  2. Hot Or Not Script Upload Error
    By marya in forum ASP Development
    Replies: 5
    Last Post: October 14th, 2004, 08:12 PM
  3. Huge / Pure upload?
    By fatmanman in forum ASP Development
    Replies: 0
    Last Post: September 14th, 2004, 06:20 AM
  4. Replies: 2
    Last Post: August 27th, 2004, 03:58 PM
  5. Upload script
    By kutty in forum ASP Development
    Replies: 0
    Last Post: October 1st, 2003, 03:36 PM

IMN logo majestic logo threadwatch logo seochat tools logo