private void SaveData() { LStblBranchDAL _dalLSTblBranch = null; Hashtable _htParameters = null; int iNextID = 0; try { _dalLSTblBranch = new LStblBranchDAL(); _htParameters = new Hashtable(); MPF23.Shared.Mapper.UIToDB.Map(pnlBody.Controls, _htParameters); Utility.ApplyDefaultProp(_htParameters); if (Request.Params["action"] == "add") { _dalLSTblBranch.Insert(_htParameters, ref iNextID); } else { _dalLSTblBranch.Update(_htParameters); iNextID = Int32.Parse(lblBRANCH.Text); } Utility.ShowMessageBox(this, Utility.SAVE_DATA_SUCCESS_MESSAGE, null, "lstblbranchdetail.aspx?action=edt&id=" + iNextID.ToString()); } catch (Exception ex) { Utility.ShowMessageBox(this, Utility.SAVE_DATA_FAIL_MESSAGE, ex, null); } }