Server Error in '/' Application.

Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount.

Source Error:


Line 87:             Liste.CurrentPageIndex = Reihenfolge - 1
Line 88:         End If
Line 89:         Liste.DataBind()
Line 90: 
Line 91:         Liste.SelectedIndex = 0

Source File: D:\vhosts\h152013.winweb23.servicehoster.ch\public_html\fotos_details.aspx.vb    Line: 89

Stack Trace:


[HttpException (0x80004005): Invalid CurrentPageIndex value. It must be >= 0 and < the PageCount.]
   System.Web.UI.WebControls.DataGrid.CreateControlHierarchy(Boolean useDataSource) +8745726
   System.Web.UI.WebControls.BaseDataList.OnDataBinding(EventArgs e) +54
   System.Web.UI.WebControls.BaseDataList.DataBind() +55
   fotos_details.Liste_anzeigen() in D:\vhosts\h152013.winweb23.servicehoster.ch\public_html\fotos_details.aspx.vb:89
   fotos_details.Page_Load(Object sender, EventArgs e) in D:\vhosts\h152013.winweb23.servicehoster.ch\public_html\fotos_details.aspx.vb:20
   System.Web.UI.Control.OnLoad(EventArgs e) +99
   System.Web.UI.Control.LoadRecursive() +50
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627


Version Information: Microsoft .NET Framework Version:2.0.50727.9061; ASP.NET Version:2.0.50727.9062