Example #1
0
 protected void Application_Start(object sender, EventArgs e)
 {
     try
     {
         //RouteTable.Routes.MapHubs();
         ApplicationController objAppController = new ApplicationController();
         if (objAppController.IsInstalled())
         {
             SageFrameConfig           SageConfig    = new SageFrameConfig();
             RolesManagementController objController = new RolesManagementController();
             RolesManagementInfo       res           = objController.GetRoleIDByRoleName(SystemSetting.AnonymousUsername);
             if (res != null)
             {
                 SystemSetting.ANONYMOUS_ROLEID = res.RoleId.ToString();
             }
             SageFrameSettingKeys.PageExtension = SageConfig.GetSettingsByKey(SageFrameSettingKeys.SettingPageExtension);
             bool isSchedulerOn = bool.Parse(SageConfig.GetSettingValueByIndividualKey(SageFrameSettingKeys.Scheduler));
             RegisterRoutes(RouteTable.Routes);
             if (isSchedulerOn)
             {
                 RunSchedule();
             }
         }
     }
     catch
     {
     }
 }
 protected void Application_Start(object sender, EventArgs e)
 {
     try
     {
         ApplicationController objAppController = new ApplicationController();
         if (objAppController.IsInstalled())
         {
             SageFrameConfig           pagebase      = new SageFrameConfig();
             RolesManagementController objController = new RolesManagementController();
             RolesManagementInfo       res           = objController.GetRoleIDByRoleName(SystemSetting.AnonymousUsername);
             if (res != null)
             {
                 SystemSetting.ANONYMOUS_ROLEID = res.RoleId.ToString();
             }
             bool IsUseFriendlyUrls = pagebase.GetSettingBollByKey(SageFrameSettingKeys.UseFriendlyUrls);
             SageFrameSettingKeys.PageExtension = pagebase.GetSettingsByKey(SageFrameSettingKeys.SettingPageExtension);
             bool isSchedulerOn = pagebase.GetSettingBollByKey(SageFrameSettingKeys.Scheduler);
             if (IsUseFriendlyUrls)
             {
                 RegisterRoutes(RouteTable.Routes);
             }
             if (isSchedulerOn)
             {
                 RunSchedule();
             }
         }
     }
     catch
     {
     }
 }
 protected void Application_Start(object sender, EventArgs e)
 {
     try
     {
         ApplicationController objAppController = new ApplicationController();
         if (objAppController.IsInstalled())
         {
             SageFrameConfig           SageConfig    = new SageFrameConfig();
             RolesManagementController objController = new RolesManagementController();
             RolesManagementInfo       res           = objController.GetRoleIDByRoleName(SystemSetting.AnonymousUsername);
             if (res != null)
             {
                 SystemSetting.ANONYMOUS_ROLEID = res.RoleId.ToString();
             }
             SageFrameSettingKeys.PageExtension = SageConfig.GetSettingsByKey(SageFrameSettingKeys.SettingPageExtension);
             RegisterRoutes(RouteTable.Routes);
         }
     }
     catch (Exception ex)
     {
     }
 }