I have Default.aspx page, which inherits from BasePage.cs, which inherits from System.Web.UI.Page. BasePage is where I do some common things every page must do upon loading
You can throw an exception, that will exit code execution, but still redirect:
HttpContext.Current.Response.Redirect("/login", true); throw new Exception("Unauthorized Access");