/// <summary> /// Returns and clears the last StageBitz exception that occured in StageBitz system. /// </summary> public static StageBitzException GetLastException() { if (HttpContext.Current.Session["LastException"] == null) { return(null); } StageBitzException ex = (StageBitzException)HttpContext.Current.Session["LastException"]; HttpContext.Current.Session["LastException"] = null; return(ex); }
public static void ThrowException(StageBitzException ex) { HttpContext.Current.Session["LastException"] = ex; throw ex; }