Ejemplo n.º 1
0
        public void BindDataGrid()
        {
            try
            {
                //dtTotal = iTotal.GetInventoryBranchItemDetail(Request.QueryString["Period"].ToString(), Request.QueryString["Branch"].ToString());
                //lblPeriod.Text = "Period : " + Request.QueryString["Period"].ToString();
                //  hidPeriod.Value = cldStartDt.SelectedDate.ToShortDateString();

                dtTotal = iTotal.GetInventoryBrActivity(Request.QueryString["Branch"].ToString(), Request.QueryString["Period"].ToString());


                if (dtTotal != null && dtTotal.Rows.Count > 0)
                {
                    dgBranchActivity.DataSource = dtTotal;
                    dgBranchActivity.DataBind();
                    dgBranchActivity.Visible = true;
                    lblStatus.Visible        = false;
                }
                else
                {
                    dgBranchActivity.Visible = false;
                    lblStatus.Visible        = true;
                    lblStatus.Text           = "No Records Found";
                }
            }
            catch (Exception ex)
            {
                throw;
            }
        }
Ejemplo n.º 2
0
        public void BindDataGrid()
        {
            try
            {
                lblPeriod.Text  = "Period : " + cldStartDt.SelectedDate.ToShortDateString();
                hidPeriod.Value = cldStartDt.SelectedDate.ToShortDateString();

                dtTotal = iTotal.GetInventoryBrActivity(branchID, cldStartDt.SelectedDate.ToShortDateString());


                if (dtTotal != null && dtTotal.Rows.Count > 0)
                {
                    dgBranchActivity.DataSource = dtTotal;
                    dgBranchActivity.DataBind();
                    dgBranchActivity.Visible = true;
                    lblStatus.Visible        = false;
                }
                else
                {
                    dgBranchActivity.Visible = false;
                    lblStatus.Visible        = true;
                    lblStatus.Text           = "No Records Found";
                }

                if (hidShowMode.Value == "Show")
                {
                    ScriptManager.RegisterClientScriptBlock(this, typeof(Page), "ShoW", "ShowPanel();", true);
                }
                else if (hidShowMode.Value == "ShowL")
                {
                    ScriptManager.RegisterClientScriptBlock(this, typeof(Page), "ShoWL", "ShowHide('Show');", true);
                }
                else if (hidShowMode.Value == "HideL")
                {
                    ScriptManager.RegisterClientScriptBlock(this, typeof(Page), "ShoWL", "ShowHide('Hide');", true);
                }
            }
            catch (Exception ex)
            {
                throw;
            }
        }