Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ASP.NET 2.0 Write File (IIS 6.0/Windows 2003)

0 views
Skip to first unread message

Henok Girma

unread,
Apr 16, 2008, 5:38:19 PM4/16/08
to
Hello,
I wanted to write to a folder from my ASP.NET web app, but i get

Access to the path 'C:\Inetpub\wwwroot\Test\Logs\test.log' is denied. at
System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at
System.IO.FileStream.Init(String path, FileMode mode, FileAccess access,
Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize,
FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean
bFromProxy) at System.IO.FileStream..ctor(String path, FileMode mode,

here is what i did

i created a Virtual Directory Test
under it there is a folder Logs
i set the propery from IIS of the logs folder to 'write'

i changed the security permission of the folder from windows explorer(right
click|properties)
and added the user IUSR_<MachineName> and ASPNET user.. i gave both users
FULL ACCESS, yet i am still not able to write to that folder.

am I missing something?

any help is greatly appreciated

Henok Girma

unread,
Apr 16, 2008, 5:44:43 PM4/16/08
to
ok, i got it.. i had add to the user IIS_WPG..

"Henok Girma" <re...@here.only.com> wrote in message
news:2AB2945A-EAB7-4C8B...@microsoft.com...

0 new messages