954,600 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Upload CSV

Hi please help with the coed to upload a CSV file. i triied using this code which i used on msome of my pages to upload files like pictures and text files and it works pefactly

strFile = "C:\TBP_IntdevResellerReport.csv  "
set galaxy = Server.CreateObject("SiteGalaxyUpload.Form")

if galaxy("upload_btn") = "Upload" then

     file=galaxy("upload_file")

     if len(file) > 0 then 
        
        galaxy("upload_file").SaveAs (strFile)

        set galaxy=nothing
       
       response.redirect("voise_calls.asp")
     end if 
end if

response.write "<form name=""upload_form""  enctype=""multipart/form-data"" action=""voise_calls.asp"" method=""post"">"
    response.write "<p> Please select file to upload:</p>"
    response.writye "<input type=""file"" name=""upload_file"" size=""30""/>"
    response.write"<br/><br/><input type=""submit"" name=""upload_btn"" value=""Upload"" class=""FormButtons"" />"
</form>


but gives me an error that says Failed to read binary data

but if i load other type of files it works please help

you dont have to fix my code if you have one that will work better
thanx in advance

PotaZinga
Newbie Poster
16 posts since Jul 2010
Reputation Points: 10
Solved Threads: 0
 

I see an error in line 20. It should be

response.write
jsmall26
Light Poster
36 posts since Jan 2008
Reputation Points: 10
Solved Threads: 3
 

OK i checked that and still the code don't read the file but it can read for other type of files like text files or pictures but not CSV files..

PotaZinga
Newbie Poster
16 posts since Jul 2010
Reputation Points: 10
Solved Threads: 0
 

Hey dear.
It a mistake. It's not an error
when you will write this program. You can right it........

sports channels

Michel88
Newbie Poster
5 posts since Sep 2010
Reputation Points: 10
Solved Threads: 2
 

and i did ryt it :D i just got it working the problem want the my code the problem was with my file it was to large... :D

PotaZinga
Newbie Poster
16 posts since Jul 2010
Reputation Points: 10
Solved Threads: 0
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You