The Specifics of: How do I build a website that the user can download a zipped file from?
Update: Sorry Tom didn't post that message. Should be pay attention more closely.
Update: Sorry Tom didn't post that message. Should be pay attention more closely.
OK, here goes, specifically and without having to learn another programing language.
lets say That I've opened up Visual Studio.Net 2003. Then I clicked File - New - Project. Under "Project Type" I clicked "Visual Basic", Under "Templates" I clicked "ASP.NET Web Application", and in the Location box I typed http://WWW.TomCsWebsite.com/WebApplication1. Then I clicked OK. After The Website was Built I dragged one Button on it from the tool box. On the same server as that web site is a File called TomCsFile.zip . I have a friend named Joe who lives in New Jersey. at 10pm Joe is going to open his web browser and go to that website and click that button. When he does that I want the TomCsfile.Zip to be copied from my server to his computer. What code do I have to put in the buttonclicks eventhandeler to make that happen?
Thanks
Update:
Mr. Kean's suggestions weren't helpful, although I did try to be more specific in my second posting. the Sales literature for VS.net claims that you can build functional Websites. I down load files from the Internet all the time, if programming such a task isn't possible Microsoft has lost touch with the rest of the computerized world. Anyway when you build website using VS.NET you are using ASP.net, if it's easier to learn ASP.net why bother with VS.net.
Mr. Ahmad's information is appreciated but it didn't solve the problem. I listed the results of my investigation on the subjects below:
Request.files- I couldn't find it in the MSDN help files (without filter), tried it in the event handeler verbatim and got an error. I lost track trying to resolve the error message.
<input type=file> server control - It's a very broad subject in the help files.
The ones below are for saving items_ "on the Web server's local disk." which is the inverse of what I'm trying to do.
HttpPostedFile.InputStream
HttpPostedFile.ContentType
HttpPostedFile.FileName
HttpPostedFile.SaveAs(fileLocation)
I eventually found the following code, and it works but the website's programmer must pre-determine where the file will be stored on the user's computer. Every program I've ever downloaded on the Internet had a window that let me determine where to the file would be saved.
Dim SourceFile As String
Dim DestinationFile As String
SourceFile = "E:\telemarketers\20041215.txt" ' Define source file name.
DestinationFile = "E:\20041215.txt" ' Define target file name.
FileCopy(SourceFile, DestinationFile) ' Copy source to target.
So the next question is how do I write the code that allows the user to determine where the file will be saved?
Any constructive help is appreciated.
Thanx
Tom
The reason I didn't respond was because it is an off-topic post.
As I stated in my first post AND second post you need to post it in the correct forum: http://forums.asp.net