trying to run the following code on:
protected void Button1_Click(object sender, EventArgs e)
{
if (NewFolderName.Text = "")
{
try
{
string newFolderName = @"c:\domains\[domainname]\wwwroot\Uploads\aaa";
Directory.CreateDirectory(newFolderName);
Page_Load(this, new EventArgs());
}
catch (Exception ex)
{
message.Text = "
" + ex.Message +"
";
}
}
}
generate the following exception:
Access to the path \c:\domains\[domainname]\wwwroot\Uploads\aaa; is denied
please advise.
protected void Button1_Click(object sender, EventArgs e)
{
if (NewFolderName.Text = "")
{
try
{
string newFolderName = @"c:\domains\[domainname]\wwwroot\Uploads\aaa";
Directory.CreateDirectory(newFolderName);
Page_Load(this, new EventArgs());
}
catch (Exception ex)
{
message.Text = "
" + ex.Message +"
";
}
}
}
generate the following exception:
Access to the path \c:\domains\[domainname]\wwwroot\Uploads\aaa; is denied
please advise.
Comment