Upload/Download Newbie Question

G

Guest

Hello, I am following along with an example of how to do uploads and download
from your application.

The download seems to wok just fine, but the upload does not. Each time I
attempt to upload, I get and exception with the error message being "{"Logon
failure: unknown user name or bad password.\r\n" }". I am trying to move the
file to shared directory on another server, and I am guessing that perhaps I
need to do something on my shared server to allow my application to be able
to write files to it. What exactly do I need to do, or is there some other
error? Here is the code I an using to upload files....

string loadDir = @"e:\products\Speed\Attachments";
System.Web.HttpPostedFile postedFile = uploadedFile.PostedFile;
string filename = Path.GetFileName(postedFile.FileName);
string contentType = postedFile.ContentType;
int contentLength = postedFile.ContentLength;
postedFile.SaveAs(loadDir + _DirectorySeparatorChar.ToString() + filename);

Are there some considerations that I should make for where I locate the
directory where I uploade files? I think I have heard that is should
segregated from where my application is, does this mean the same server or
should it be isolated to a different server?

Thanks in advance for your assistance!!!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,143
Latest member
DewittMill
Top