private void SaveProcCode(string _type) { string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url); using (Utils utility = new Utils()) { utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod()); } DataSet _billDs = new DataSet(); try { foreach (DataGridItem dgiProcedureCode in grdProcedure.Items) { CheckBox chkEmpty = (CheckBox)dgiProcedureCode.Cells[1].FindControl("chkSelect"); if (chkEmpty.Checked == true) { _visitBO = new Bill_Sys_Visit_BO(); _objAL = new ArrayList(); _objAL.Add(dgiProcedureCode.Cells[2].Text.ToString()); _objAL.Add(dgiProcedureCode.Cells[3].Text.ToString()); _objAL.Add(_type); _objAL.Add(txtCompanyID.Text); //_objAL.Add(extddlVisitRoom.Text); _objAL.Add(extddlSpeciality.Text); _visitBO.saveVisit(_objAL); _objAL.Clear(); _procBO = new Bill_Sys_Visit_BO(); _objAL.Add(dgiProcedureCode.Cells[1].Text.ToString()); _objAL.Add(dgiProcedureCode.Cells[2].Text.ToString()); _objAL.Add(dgiProcedureCode.Cells[3].Text.ToString()); _objAL.Add(dgiProcedureCode.Cells[4].Text.ToString()); _objAL.Add(dgiProcedureCode.Cells[5].Text.ToString()); _objAL.Add(extddlSpeciality.Text); _procBO.saveProc(_objAL); } } } catch (Exception ex) { Elmah.ErrorSignal.FromCurrentContext().Raise(ex); using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } string str2 = "Error Request=" + id + ".Please share with Technical support."; base.Response.Redirect("Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2); } //Method End using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } }
protected void btnSave_Click(object sender, EventArgs e) { string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url); using (Utils utility = new Utils()) { utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod()); } if (rdoVisitType.SelectedValue.ToString() != "") { txtVisitType.Text = rdoVisitType.SelectedValue.ToString(); } else { txtVisitType.Text = "0"; } _saveOperation = new SaveOperation(); try { _saveOperation.WebPage = this.Page; _saveOperation.Xml_File = "procedurecode.xml"; _saveOperation.SaveMethod(); _visitBO = new Bill_Sys_Visit_BO(); _objAL = new ArrayList(); _objAL.Add(txtProcedureCode.Text); _objAL.Add(txtProcedureDesc.Text); // _objAL.Add(txtProcedureAmount.Text); _objAL.Add(ddlType.SelectedItem.ToString()); _objAL.Add(txtCompanyID.Text); _objAL.Add(extddlProCodeGroup.Text); _visitBO.saveVisit(_objAL); SaveAmount(); BindGrid(); lblMsg.Visible = true; lblMsg.Text = " Procedure Code Saved successfully ! "; } catch (Exception ex) { Elmah.ErrorSignal.FromCurrentContext().Raise(ex); using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } string str2 = "Error Request=" + id + ".Please share with Technical support."; base.Response.Redirect("Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2); } //Method End using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } }
protected void btnVisitSave_Click(object sender, EventArgs e) { string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url); using (Utils utility = new Utils()) { utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod()); } try { _visitBO = new Bill_Sys_Visit_BO(); _objAL = new ArrayList(); _objAL.Add(txtVisitCode.Text); _objAL.Add(txtVisitDescription.Text); _objAL.Add(txtVisitID.Text); _objAL.Add(txtCompanyID.Text); _objAL.Add(extddlVisitRoom.Text); _visitBO.saveVisit(_objAL); BindGrid(); lblMsg.Visible = true; lblMsg.Text = "Visit Saved Successfully ...!"; } catch (Exception ex) { Elmah.ErrorSignal.FromCurrentContext().Raise(ex); using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } string str2 = "Error Request=" + id + ".Please share with Technical support."; base.Response.Redirect("Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2); } //Method End using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } }
protected void btnUpdate_Click(object sender, EventArgs e) { string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url); using (Utils utility = new Utils()) { utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod()); } _editOperation = new EditOperation(); txtVisitType.Text = rdoVisitType.SelectedValue.ToString(); try { _editOperation.WebPage = this.Page; _editOperation.Xml_File = "procedurecode.xml"; _editOperation.Primary_Value = Session["ProcedureCodeID"].ToString(); _editOperation.UpdateMethod(); if (Session["VisitID"] != null) { txtVisitID.Text = ddlType.SelectedItem.ToString(); // changed by shailesh 1-April-2010, accepted the selected value of ddltype txtRoomId.Text = extddlProCodeGroup.Text; _editOperation = new EditOperation(); _editOperation.Primary_Value = Session["VisitID"].ToString(); _editOperation.WebPage = this.Page; _editOperation.Xml_File = "NewVisit.xml"; _editOperation.UpdateMethod(); } else { _visitBO = new Bill_Sys_Visit_BO(); _objAL = new ArrayList(); _objAL.Add(txtProcedureCode.Text); _objAL.Add(txtProcedureDesc.Text); // _objAL.Add(txtProcedureAmount.Text); _objAL.Add(ddlType.SelectedItem.ToString()); // changed by shailesh 1-April-2010, accepted the selected value of ddltype _objAL.Add(""); _objAL.Add(txtCompanyID.Text); _objAL.Add(extddlProCodeGroup.Text); _visitBO.saveVisit(_objAL); } UpdateAmount(); BindGrid(); lblMsg.Visible = true; lblMsg.Text = " Procedure Code Updated successfully ! "; } catch (Exception ex) { Elmah.ErrorSignal.FromCurrentContext().Raise(ex); using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } string str2 = "Error Request=" + id + ".Please share with Technical support."; base.Response.Redirect("Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2); } //Method End using (Utils utility = new Utils()) { utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod()); } }