protected void OnConfirm(object sender, CommandEventArgs e) { try { DataTable dtQuotationList = new DataTable(); dtQuotationList.Columns.Add("Qtncode"); dtQuotationList.Columns.Add("amount"); string[] strIds = e.CommandArgument.ToString().Split(','); string reqCode = strIds[0].ToString(); string DocumentCode = strIds[1].ToString(); string vesselCode = strIds[2].ToString(); string SupplierCode = strIds[3].ToString(); string OrdCode = strIds[4].ToString(); string QuotCode = strIds[5].ToString(); DataRow dtrow = dtQuotationList.NewRow(); dtrow[0] = strIds[5].ToString(); dtrow[1] = "0"; dtQuotationList.Rows.Add(dtrow); TechnicalBAL objTechBAL = new TechnicalBAL(); int insRec = objTechBAL.UpdatePOConfirmation(reqCode, DocumentCode, SupplierCode, vesselCode, OrdCode, QuotCode); BLL_PURC_Purchase objPurc = new BLL_PURC_Purchase(); objPurc.InsertRequisitionStageStatus(reqCode, vesselCode, DocumentCode, "UPD", " ", Convert.ToInt32(Session["USERID"]), dtQuotationList); String msg = String.Format("alert('Order has been Confirmed'); window.close();"); ScriptManager.RegisterStartupScript(Page, Page.GetType(), "msg", msg, true); ucCustomPagerItems.isCountRecord = 1; BindData(); } catch (Exception ex) { UDFLib.WriteExceptionLog(ex); } }