V
VB Programmer
When I run this line:
Dim sw As New System.IO.StreamWriter(strFileName)
I get this error:
System.UnauthorizedAccessException: Access to the path
"c:\inetpub\wwwroot\MyWeb\Resources\Templates\MyPage.Html" is denied. at
System.IO.__Error.WinIOError(Int32 errorCode, String str) at
System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access,
FileShare share, Int32 bufferSize, Boolean useAsync, String msgPath, Boolean
bFromProxy) at System.IO.FileStream..ctor(String path, FileMode mode,
FileAccess access, FileShare share, Int32 bufferSize) at
System.IO.StreamWriter.CreateFile(String path, Boolean append) at
System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding,
Int32 bufferSize) at System.IO.StreamWriter..ctor(String path) at
EarlyAlert3.EditHtml.cmdSave_Click(Object sender, EventArgs e) in
c:\inetpub\wwwroot\MyWeb\EditHtml.aspx.vb:line 172
Any ideas?
Thanks.
Dim sw As New System.IO.StreamWriter(strFileName)
I get this error:
System.UnauthorizedAccessException: Access to the path
"c:\inetpub\wwwroot\MyWeb\Resources\Templates\MyPage.Html" is denied. at
System.IO.__Error.WinIOError(Int32 errorCode, String str) at
System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access,
FileShare share, Int32 bufferSize, Boolean useAsync, String msgPath, Boolean
bFromProxy) at System.IO.FileStream..ctor(String path, FileMode mode,
FileAccess access, FileShare share, Int32 bufferSize) at
System.IO.StreamWriter.CreateFile(String path, Boolean append) at
System.IO.StreamWriter..ctor(String path, Boolean append, Encoding encoding,
Int32 bufferSize) at System.IO.StreamWriter..ctor(String path) at
EarlyAlert3.EditHtml.cmdSave_Click(Object sender, EventArgs e) in
c:\inetpub\wwwroot\MyWeb\EditHtml.aspx.vb:line 172
Any ideas?
Thanks.