Access Denied

M

mt

Hello

Here is my setup
IIS 6 on a Server 2003 machin
..NET framework 1.

I'm trying to copy files from clients to my 2003 server using a HtmlInputFile control.

The code
Tr
'upload the file from the client to the server folde
UploadFileInput.PostedFile.SaveAs("\\servername\e$\folder\file.txt"
Catch ex As Exceptio
'error handling stuf
End Tr

IIS 6 is configured to NOT ALLOW anonymous access. It is set to use windows authentication. The web.config file is set to use impersonation. Authenticated users and the server's ASPNET account have full control over the folder in which I'm trying to dump the files.

When the attempt is made to shove the file into the target folder, I get an "Access to the path "\\servername\e$\folder\file.txt" is denied." error. The mscorlib.dll is the source of the error for whatever that is worth

I can get a step further into the process if I share the folder Then I get this error
Access to the path "c:\windows\system32\inetsrv\file.txt" is denie
I really rather use the first method and skip sharing.

Any ideas? I'm sure it is something obvious

Regards
m
 
A

Aaron Margosis [MS]

If "e$" is an administrative share of your E: drive (like c$ is for your C:
drive), then only administrators can access it. Likewise, stuff under
system32 is generally not writable by non-administrative accounts.

HTH

-- Aaron



mt said:
Hello,

Here is my setup:
IIS 6 on a Server 2003 machine
.NET framework 1.1

I'm trying to copy files from clients to my 2003 server using a HtmlInputFile control.

The code:
Try
'upload the file from the client to the server folder
UploadFileInput.PostedFile.SaveAs("\\servername\e$\folder\file.txt")
Catch ex As Exception
'error handling stuff
End Try

IIS 6 is configured to NOT ALLOW anonymous access. It is set to use
windows authentication. The web.config file is set to use impersonation.
Authenticated users and the server's ASPNET account have full control over
the folder in which I'm trying to dump the files.
When the attempt is made to shove the file into the target folder, I get
an "Access to the path "\\servername\e$\folder\file.txt" is denied." error.
The mscorlib.dll is the source of the error for whatever that is worth.
 

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,769
Messages
2,569,582
Members
45,066
Latest member
VytoKetoReviews

Latest Threads

Top