예제 #1
0
 public void BindPageDetails()
 {
     try
     {
         lblCurrentPageRecCount.Text = " " + (ddlPages.SelectedIndex + 1).ToString();
         lblTotalNoOfRec.Text        = " " + ddlPages.Items.Count.ToString();
         lblCurrentPage.Text         = " " + (ddlPages.SelectedIndex + 1).ToString();
         lblTotalPage.Text           = " " + ddlPages.Items.Count.ToString();
         lblCurrentTotalRec.Text     = " " + (ddlPages.SelectedIndex + 1).ToString();
         pnlPager.Update();
         // see if page has been filtered
         if (Session["FilteredRcptData"] == null)
         {
             dv = new DataView((DataTable)Session["LPNRcptData"], "PageNo = " + (ddlPages.SelectedIndex + 1).ToString(),
                               SortHidden.Value, DataViewRowState.CurrentRows);
         }
         else
         {
             dv = new DataView((DataTable)Session["FilteredRcptData"], "PageNo = " + (ddlPages.SelectedIndex + 1).ToString(),
                               SortHidden.Value, DataViewRowState.CurrentRows);
         }
         XDocGridView.DataSource = dv;
         XDocGridView.DataBind();
     }
     catch (Exception e3)
     {
         lblErrorMessage.Text = "BindPageDetails Error " + e3.ToString();
         MessageUpdatePanel.Update();
     }
 }
예제 #2
0
 public void DetailGridView_PageIndexChanging(object sender, GridViewPageEventArgs e)
 {
     XDocGridView.DataSource = (DataTable)Session["LPNRcptData"];
     XDocGridView.PageIndex  = e.NewPageIndex;
     XDocGridView.DataBind();
     DetailGridPanel.Height = new Unit(double.Parse(DetailGridHeightHidden.Value), UnitType.Pixel);
     DetailGridPanel.Width  = new Unit(double.Parse(DetailGridWidthHidden.Value), UnitType.Pixel);
 }
예제 #3
0
    protected void GetData(string Loc, string BegLPN, string EndLPN, string BegBOL, string EndBOL, string BegDate, string EndDate)
    {
        Session["FilteredXDocData"] = null;
        try
        {
            lblErrorMessage.Text = "";
            MessageUpdatePanel.Update();
            dt = null;
            lblErrorMessage.Text = "";
            // get the data.
            dt = CheckError(XDockData.SearchUnprocessed(
                                Loc
                                , BegLPN
                                , EndLPN
                                , BegBOL
                                , EndBOL
                                , BegDate
                                , EndDate
                                ));
            if ((dt != null) && (dt.Rows.Count > 0))
            {
                dt.Columns.Add("PageNo");
                RePage(dt);
                Session["XDocData"] = dt;
                BindPageDetails();
            }
            else
            {
                //lblErrorMessage.Text = "Error " + _ToLoc + ":" + _BegContainer + ":" + _EndContainer + ":"
                //     + _BegBOL + ":" + _EndBOL + ":"
                //     + BegDate.SelectedDate.ToShortDateString() + ":" + EndDate.SelectedDate.ToShortDateString();
                lblErrorMessage.Text = "No Records Found.";
                XDocGridView.DataBind();
                Session["XDocData"] = dt;
            }
            MessageUpdatePanel.Update();
        }
        catch (Exception e3)
        {
            lblErrorMessage.Text = "pContainerCrossDocForm Error " + e3.Message + ", " + e3.ToString();
            MessageUpdatePanel.Update();
        }
        DetailUpdatePanel.Update();

        SelectorUpdatePanel.Visible = false;
        SearchUpdatePanel.Visible   = true;
        DetailGridPanel.Visible     = true;
        pnlPager.Visible            = true;
        BottomPanel.Visible         = true;
        ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "", "SetHeight();", true);
    }
예제 #4
0
 protected void GetData()
 {
     Session["FilteredRcptData"] = null;
     try
     {
         dt = null;
         lblErrorMessage.Text = "";
         MessageUpdatePanel.Update();
         // get the data.
         dt = CheckError(ReceiptData.SearchUnprocessed(LocationDropDownList.SelectedItem.Value.ToString().Trim()
                                                       , LPNBeg.Text.ToString().Trim()
                                                       , ""
                                                       , BOLBeg.Text.ToString().Trim()
                                                       , ""
                                                       , BegDate.SelectedDate.ToShortDateString()
                                                       , EndDate.SelectedDate.ToShortDateString()
                                                       ));
         Session["LPNRcptData"] = dt;
         if ((dt != null) && (dt.Rows.Count > 0))
         {
             dt.Columns.Add("PageNo");
             RePage(dt);
             BindPageDetails();
             FindSubmit.Visible = true;
         }
         else
         {
             //lblErrorMessage.Text = "Error " + _ToLoc + ":" + _BegContainer + ":" + _EndContainer + ":"
             //     + _BegBOL + ":" + _EndBOL + ":"
             //     + BegDate.SelectedDate.ToShortDateString() + ":" + EndDate.SelectedDate.ToShortDateString();
             lblErrorMessage.Text = "No Records Found..";
             MessageUpdatePanel.Update();
             FindSubmit.Visible = false;
             XDocGridView.DataBind();
         }
         SearchUpdatePanel.Update();
     }
     catch (Exception e3)
     {
         lblErrorMessage.Text = "pContainerCrossDocForm Error " + e3.Message + ", " + e3.ToString();
         MessageUpdatePanel.Update();
     }
     DetailUpdatePanel.Update();
     SelectorUpdatePanel.Visible = false;
     SearchUpdatePanel.Visible   = true;
     DetailGridPanel.Visible     = true;
     pnlPager.Visible            = true;
     BottomPanel.Visible         = true;
 }