Re: Invalid CurrentPageIndex error

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Alvin Bruney [MVP] (vapor)
Date: 05/07/04

  • Next message: psibertrip: "Working TableStyle Not Working on a Second DataGrid"
    Date: Fri, 7 May 2004 07:17:17 -0500
    
    

    thanks, i'll test and submit.

    -- 
    Regards,
    Alvin Bruney
    [ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
    Got tidbits? Get it here... http://tinyurl.com/27***
    "Spike" <spooky2000@usa.com> wrote in message 
    news:9c0f01c43422$32b5bc80$a501280a@phx.gbl...
    > Oops I seem to have missed out some important info in the
    > report. Heres the updated report
    > -----------------------------
    > Setting PageSize property of DataGrid to
    > System.Integer.MaxValue gives the following error
    >
    > Invalid CurrentPageIndex value. It must be >= 0 and < the
    > PageCount.
    >
    > Steps to reproduce the error
    > 1. Create a new ASP.Net Web project.
    > 2. Add a WebForm to the project.
    > 3. Add a DataGird (DataGrid1) to the WebForm.
    > 4. Enable Paging for the datagrid.
    > 5. Add atleast 1 ButtonColumn to the DataGrid
    > 6. Write code to bind the DataGrid to any datasource.
    > 7. Trap the ItemCommand Event for the Button Column.
    > 8. In the ItemCommand event add the following code
    >   DataGrid1.Pagesize = System.Int32.MaxValue.
    >   Code to bind the datagrid to datasource.
    > 9. Run the application.
    > 10. Clicking on the ButtonColumn should give the error.
    > ---------------------------------------------
    >
    >>-----Original Message-----
    >>Well here's the report.
    >>-----------------------------
    >>Setting PageSize property of DataGrid to
    >>System.Integer.MaxValue gives the following error
    >>
    >>Invalid CurrentPageIndex value. It must be >= 0 and < the
    >>PageCount.
    >>
    >>Steps to reproduce the error
    >>1. Create a new ASP.Net Web project.
    >>2. Add a WebForm to the project.
    >>3. Add a DataGird (DataGrid1) to the WebForm.
    >>4. Enable Paging for the datagrid.
    >>5. Add atleast 1 ButtonColumn to the DataGrid
    >>6. Write code to bind the DataGrid to any datasource.
    >>7. Trap the ItemCommand Event for the Button Column.
    >>8. In the ItemCommand event add the following code
    >>   DataGrid1.Pagesize = System.Int32.MaxValue.
    >>9. Run the application.
    >>10. Clicking on the ButtonColumn should give the error.
    >>---------------------------------------------
    >>Hope this would suffice
    >>
    >>>-----Original Message-----
    >>>write up a complete report and post it here. I'll route
    >>it to product
    >>>support. Sorry, I should have offered you this option in
    >>the first place.
    >>>
    >>>-- 
    >>>Regards,
    >>>Alvin Bruney
    >>>[ASP.NET MVP
    >>http://mvp.support.microsoft.com/default.aspx]
    >>>Got tidbits? Get it here... http://tinyurl.com/27***
    >>
    >>.
    >> 
    

  • Next message: psibertrip: "Working TableStyle Not Working on a Second DataGrid"
  • Quantcast