private void UpdateItemDetails()
    {
        DL_WEB.DAL.Client.Update oUpdate = new DL_WEB.DAL.Client.Update();
        oUpdate.LoadByPrimaryKey(UpdateID);

        if (oUpdate.RowCount > 0)
        {
            oUpdate.Name           = tbUpdateName.Text;
            oUpdate.Description    = reDescription.Html;
            oUpdate.BuildDate      = Micajah.Common.Helper.Convert.o2dt(tbBuildDate.Text);
            oUpdate.UpdateStatusID = Micajah.Common.Helper.Convert.o2i(ddlUpdateStatus.SelectedValue);
            oUpdate.UpdateGroupID  = Micajah.Common.Helper.Convert.o2i(ddlUpdateGroup.SelectedValue);
            oUpdate.BuildNumber    = tbBuuildNumber.Text;

            oUpdate.Save();

            #region Registering Activity

            DL_WEB.DAL.Client.ActivityLog.Instance.RegisterActivity(ActivityTypes.UpdateUpdated, "Update " + oUpdate.Name + " updated", ActivityObject.Update, oUpdate.UpdateID, this.UserGUID, Context.User.Identity.Name);

            #endregion
        }
        else
        {
            throw new Exception("Update with UpdateID = " + UpdateID + " was not found.");
        }
    }
    private int SaveNewUpdate()
    {
        DL_WEB.DAL.Client.Update oUpdate = new DL_WEB.DAL.Client.Update();
        oUpdate.AddNew();
        oUpdate.ProjectID      = ProjectID;
        oUpdate.Name           = tbUpdateName.Text;
        oUpdate.Description    = reDescription.Html;
        oUpdate.BuildDate      = Micajah.Common.Helper.Convert.o2dt(tbBuildDate.Text);
        oUpdate.EnteredDate    = DateTime.Now;
        oUpdate.EnteredUserID  = DL_WEB.DAL.Client.User.Instance.GetUserIDByGUID(this.UserGUID);
        oUpdate.UpdateStatusID = DL_WEB.DAL.Client.UpdateStatus.CreatedStatusID;
        oUpdate.UpdateGroupID  = Micajah.Common.Helper.Convert.o2i(ddlUpdateGroup.SelectedValue);
        oUpdate.BuildNumber    = tbBuuildNumber.Text;
        oUpdate.UpdateStatusID = Micajah.Common.Helper.Convert.o2i(ddlUpdateStatus.SelectedValue);

        oUpdate.Save();

        #region Registering Activity

        DL_WEB.DAL.Client.ActivityLog.Instance.RegisterActivity(ActivityTypes.UpdateCreated, "Update " + oUpdate.Name + " created", ActivityObject.Update, oUpdate.UpdateID, this.UserGUID, Context.User.Identity.Name);

        #endregion

        return(oUpdate.UpdateID);
    }