예제 #1
0
 protected void Paginador1_PageChanged(object sender, CustomPageChangeArgs e)
 {
     try
     {
         grdFacturas.PageSize = (e.CurrentPageSize == 0 ? 20 : e.CurrentPageSize);
         grdFacturas.PageIndex = e.CurrentPageNumber;
         Facturas();
     }
     catch (Exception ex)
     {
         ISException.RegisterExcepcion(ex);
         panelMensaje.CssClass = "MostrarMensaje";
         lblMensaje.Text = ex.Message;
         return;
     }
 }
 protected void Paginador1_PageChanged(object sender, CustomPageChangeArgs e)
 {
     try
     {
         gridRegistroCargaArchivo.PageSize = (e.CurrentPageSize == 0 ? 10 : e.CurrentPageSize);
         gridRegistroCargaArchivo.PageIndex = e.CurrentPageNumber;
         CargaGrilla(null, null);
     }
     catch (Exception ex)
     {
         ISException.RegisterExcepcion(ex);
         panelMensaje.CssClass = "MostrarMensaje";
         lblMensaje.Text = ex.Message;
         return;
     }
 }
예제 #3
0
        protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e)
        {
            CustomPageChangeArgs args = new CustomPageChangeArgs();
            args.CurrentPageSize = Convert.ToInt32(this.ddlPageSize.SelectedItem.Value);
            args.CurrentPageNumber = 1;
            args.TotalPages = Convert.ToInt32(this.lblShowRecords.Text);
            Pager_PageChanged(this, args);

            ddlPageNumber.Items.Clear();
            for (int count = 1; count <= this.TotalPages; ++count)
                ddlPageNumber.Items.Add(count.ToString());
            ddlPageNumber.Items[0].Selected = true;
            lblShowRecords.Text = string.Format(" {0} ", this.TotalPages.ToString());
        }
예제 #4
0
        protected void ddlPageNumber_SelectedIndexChanged(object sender, EventArgs e)
        {
            CustomPageChangeArgs args = new CustomPageChangeArgs();
            args.CurrentPageSize = Convert.ToInt32(this.ddlPageSize.SelectedItem.Value);
            args.CurrentPageNumber = Convert.ToInt32(this.ddlPageNumber.SelectedItem.Text);
            args.TotalPages = Convert.ToInt32(this.lblShowRecords.Text);
            Pager_PageChanged(this, args);

            lblShowRecords.Text = string.Format(" {0} ", args.TotalPages.ToString());
        }
예제 #5
0
 void Pager_PageChanged(object sender, CustomPageChangeArgs e)
 {
     PageChanged(this, e);
     //throw new Exception("The method or operation is not implemented.");
 }
예제 #6
0
        protected void linkSiguiente_Click(object sender, EventArgs e)
        {
            int PaginaActual = Convert.ToInt32(this.ddlPageNumber.SelectedItem.Text);
            if (PaginaActual < Convert.ToInt32(this.lblShowRecords.Text))
            {
                CustomPageChangeArgs args = new CustomPageChangeArgs();
                args.CurrentPageSize = Convert.ToInt32(this.ddlPageSize.SelectedItem.Value);
                args.CurrentPageNumber = PaginaActual + 1;
                args.TotalPages = Convert.ToInt32(this.lblShowRecords.Text);
                Pager_PageChanged(this, args);

                this.ddlPageNumber.SelectedValue = args.CurrentPageNumber.ToString();
                lblShowRecords.Text = string.Format(" {0} ", args.TotalPages.ToString());
            }
        }