/// <summary> /// /// </summary> /// <param name="userName"></param> /// <param name="moduleName"></param> /// <param name="activity"></param> private void UpdateApplicationObject(Page sourcePage, string moduleName, string activity) { ActivityHelper activityList = null; try { if (sourcePage.Application[APP_OBJECT_NAME] != null) { activityList = sourcePage.Application[APP_OBJECT_NAME] as ActivityHelper; } else { activityList = new ActivityHelper(); sourcePage.Application[APP_OBJECT_NAME] = activityList; } activityList.Add(sourcePage.User.Identity.Name, "", System.DateTime.Now, moduleName, activity); } catch (Exception exception) { System.Diagnostics.Debug.Write(exception.Message,"BCC Operator - UpdateApplicationObject - Exception"); } }
public List<ActivityData> ActivityItems(System.Web.HttpContext httpContext) { ActivityHelper activityList = null; if (httpContext.Application[APP_OBJECT_NAME] != null) { activityList = httpContext.Application[APP_OBJECT_NAME] as ActivityHelper; } else { activityList = new ActivityHelper(); } return activityList.array; }