protected void slkButtonDelete_Click(object sender, EventArgs e) { try { // Delete corresponding assignment folder from the drop box if exists if (AssignmentProperties.PackageFormat == null) { DropBoxManager dropBoxMgr = new DropBoxManager(AssignmentProperties); dropBoxMgr.DeleteAssignmentFolder(); } SlkStore.DeleteAssignment(AssignmentProperties.Id); Response.Redirect(SPWeb.ServerRelativeUrl, true); } catch (ThreadAbortException) { // Calling Response.Redirect throws a ThreadAbortException which will // flag an error in the next step if we don't do this. throw; } catch (Exception exception) { errorBanner.AddException(SlkStore, new SafeToDisplayException(PageCulture.Resources.LobbyDeleteException)); SlkStore.LogException(exception); } }