Access denied to path

F

fanto

Hi everyone,

I'm new to asp.net and would really appreciate some help. Not too sure where
this post should be so sorry if it's in the wrong place.

i'm trying to upload files to a server with the following method:
myFile.PostedFile.SaveAs(Server.MapPath("upload") & strFileNameOnly)

I've changed the permissions to allow aspnet to r/w/mod the folder but it
keeps on throwing the message:
Access to path 'D:\...\upload' is denied.

I've looked through some of the other posts with similar problems with no
luck. Tearing my hair out at this stage.

If any more information is need please let me know.

Thanks,
Andrew.
 
J

Joshua Flanagan

Is D:\ a mapped network drive? If so, the access attempt will be made by
domain\machinename$ - NOT the local ASPNET account. Search around for
information about ASP.NET and impersonation across network boundaries.
 
F

fanto

cheers for the quick reply,

i'm just running asp.net on my own computer at the moment, so as far as I
know its not a mapped network drive simply a hd on my machine (is this right?
as I said I'm new to this).

i've tried <identity impersonate="false" /> and <identity impersonate="true"
/> in the web.config file, and I don't have any user accounts on the site.

have I missed your point or am I doing something else wrong?

thanks again...

Joshua said:
Is D:\ a mapped network drive? If so, the access attempt will be made by
domain\machinename$ - NOT the local ASPNET account. Search around for
information about ASP.NET and impersonation across network boundaries.
Hi everyone,
[quoted text clipped - 15 lines]
Thanks,
Andrew.
 
F

fanto via DotNetMonster.com

anyone else have any ideas? where am I going wrong??

cheers for the quick reply,

i'm just running asp.net on my own computer at the moment, so as far as I
know its not a mapped network drive simply a hd on my machine (is this right?
as I said I'm new to this).

i've tried <identity impersonate="false" /> and <identity impersonate="true"
/> in the web.config file, and I don't have any user accounts on the site.

have I missed your point or am I doing something else wrong?

thanks again...
Is D:\ a mapped network drive? If so, the access attempt will be made by
domain\machinename$ - NOT the local ASPNET account. Search around for
[quoted text clipped - 5 lines]
 

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,995
Messages
2,570,230
Members
46,820
Latest member
GilbertoA5

Latest Threads

Top