I have created one website. In that website it has different folders. I have given permission to only admins . I have created admin role and client role. when anonymous persons want to access web page in the folder. It should automatically redirected to the login page.
In page_load event what should i write I am not getting any idea. I have tried a lot.
plz help me.
thanq.
Jiteendra SampathiraoPosted Jul 9, 2011, 1:15 AM
refer this link;
Link
Krishna GaradPosted Jul 9, 2011, 1:06 AM
1) Add web.confige file in folders and write
2) In page_load
if (User.Identity.IsAuthenticated)
{
this.Page.Visible = true;
}
else
{
Response.Redirect("login.aspx");
}