File upload to a remote share not working.

R

rajesh

I am trying to upload a file using .Net's HttpPostedFile.SaveAs() to a share
on a remote server. It works fine when the share is on the same server. I
looked at the permissions on the share and they all seem to be set properly.
These permission setting are the same as what was used when we were
uploading the files using the old asp code.

Given below is the stack trace

Message:
Could not find a part of the path "\\Server01\Attachments$".

Source:
mscorlib

Stack Trace:
at System.IO.__Error.WinIOError(Int32 errorCode, String str)
at System.IO.Directory.InternalCreateDirectory(String fullPath, String
path)
at System.IO.Directory.CreateDirectory(String path)

Thank you
Rajesh
 
J

Jared

I had the same problem a week or two ago, the answer is impersonation vs.
delegation. That is why it works on the web server but not the remote share.
If you set your web site to basic authentication and have the user type in
domainname\username & password they should be able to upload and save files,
it just doesn't seem to work with windows authentication. Read the below
article.
Jared

http://msdn.microsoft.com/library/d...y/en-us/vsent7/html/vxconaspnetdelegation.asp
 
R

rajesh

Thank you. That works.


Jared said:
I had the same problem a week or two ago, the answer is impersonation vs.
delegation. That is why it works on the web server but not the remote share.
If you set your web site to basic authentication and have the user type in
domainname\username & password they should be able to upload and save files,
it just doesn't seem to work with windows authentication. Read the below
article.
Jared

http://msdn.microsoft.com/library/d...y/en-us/vsent7/html/vxconaspnetdelegation.asp
 
R

rajesh

Joined
Nov 15, 2007
Messages
2
Reaction score
0
Could anyone help me out with setting the permission so that I can upload file to a remote share? Thank you.

Tinhtam
 

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

Forum statistics

Threads
473,734
Messages
2,569,441
Members
44,832
Latest member
GlennSmall

Latest Threads

Top