void BindRejectedRecordsGrid()
        {
            DataSet dsRejectedRecords;

            if (hdnCurrentPage.Value.ToString() != "")
            {
                mypager.CurrentPage  = Int32.Parse(hdnCurrentPage.Value.ToString());
                hdnCurrentPage.Value = "";
            }

            int Count;

            try
            {
                dsRejectedRecords = rejectedRecordsBo.GetProfileFolioInputRejects(processID, "DT", mypager.CurrentPage, out Count);
            }
            catch (Exception Ex)
            {
                BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
                NameValueCollection      FunctionInfo = new NameValueCollection();

                FunctionInfo.Add("Method", "kARVYProfileFolioInputRejects.ascx:BindRejectedRecordsGrid()");

                object[] objects = new object[0];

                FunctionInfo = exBase.AddObject(FunctionInfo, objects);
                exBase.AdditionalInformation = FunctionInfo;
                ExceptionManager.Publish(exBase);
                throw exBase;
            }
            lblTotalRows.Text = hdnRecordCount.Value = Count.ToString();
            if (Count > 0)
            {
                DivPager.Style.Add("display", "visible");
            }

            if (dsRejectedRecords.Tables[0].Rows.Count > 0)
            {
                trInputNullMessage.Visible   = false;
                gvRejectedRecords.DataSource = dsRejectedRecords.Tables[0];
                gvRejectedRecords.DataBind();
            }
            else
            {
                trInputNullMessage.Visible   = true;
                gvRejectedRecords.DataSource = null;
                gvRejectedRecords.DataBind();
            }

            this.GetPageCount();
        }
Ejemplo n.º 2
0
        void BindRejectedRecordsGrid()
        {
            DataSet dsRejectedRecords;


            try
            {
                dsRejectedRecords = rejectedRecordsBo.GetProfileFolioInputRejects(processID, "KA");
                if (Cache["gvRejectedRecords" + userVo.UserId] == null)
                {
                    Cache.Insert("gvRejectedRecords" + userVo.UserId, dsRejectedRecords.Tables[0]);
                }
                else
                {
                    Cache.Remove("gvRejectedRecords" + userVo.UserId);
                    Cache.Insert("gvRejectedRecords" + userVo.UserId, dsRejectedRecords.Tables[0]);
                }
            }
            catch (Exception Ex)
            {
                BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
                NameValueCollection      FunctionInfo = new NameValueCollection();

                FunctionInfo.Add("Method", "kARVYProfileFolioInputRejects.ascx:BindRejectedRecordsGrid()");

                object[] objects = new object[0];

                FunctionInfo = exBase.AddObject(FunctionInfo, objects);
                exBase.AdditionalInformation = FunctionInfo;
                ExceptionManager.Publish(exBase);
                throw exBase;
            }



            if (dsRejectedRecords.Tables[0].Rows.Count > 0)
            {
                imgBtnrgHoldings.Visible     = true;
                gvRejectedRecords.DataSource = dsRejectedRecords.Tables[0];
                gvRejectedRecords.DataBind();
            }
            else
            {
                imgBtnrgHoldings.Visible     = false;
                gvRejectedRecords.DataSource = null;
                gvRejectedRecords.DataBind();
            }

            divGvRejectedRecords.Visible = true;
        }