首页 > 代码库 > Events in ASP.NET Master and Content Pages
Events in ASP.NET Master and Content Pages
Content page PreInit event.
Master page controls Init event.
Content controls Init event.
Master page Init event.
protected void Page_Init(object sender, EventArgs e){ //do something }
Content page Init event.
Content page Load event.
Master page Load event.
Master page controls Load event.
Content page controls Load event.
Content page PreRender event.
Master page PreRender event.
Master page controls PreRender event.
Content page controls PreRender event.
Master page controls Unload event.
Content page controls Unload event.
Master page Unload event.
Content page Unload event.
public class PageHelper { public static string CurrentPageModuleId { get { return Convert.ToString(HttpContext.Current.Request.QueryString["mid"]); } } public bool HasPagePermission() { if (string.IsNullOrEmpty(CurrentPageModuleId)) return false; return HasPagePermission(CurrentPageModuleId); } public bool HasPagePermission(string moduleId) { return true; } public bool HasFunctionPermission(string moduleFunctionType) { if (string.IsNullOrEmpty(CurrentPageModuleId)) return false; return HasFunctionPermission(CurrentPageModuleId, moduleFunctionType); } public bool HasFunctionPermission(string moduleId, string moduleFunctionType) { return true; } }
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。