471,072 Members | 1,513 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,072 software developers and data experts.

Index was out of range. Must be non-negative and less than the sizeof the collection.

I've been trying to correct this error for approx 2 days and am
having
no luck.

In a page's button clickevent , i want to bind a infragistic grid
according to two dropdown value.
At the first click it runs correctly, but when change the index of
dropdown and again click that button,
this gives an error message.

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.ArgumentOutOfRangeException: Index was out
of range. Must be non-negative and less than the size of the
collection.
Parameter name: index

Exception details
System.Collections.CollectionBase.System.Collectio ns.IList.get_Item(Int32
index) +2435961

Infragistics.WebUI.UltraWebGrid.KeyedObjectCollect ionBase.GetItem(Int32
index) +5

Infragistics.WebUI.UltraWebGrid.KeyedObjectCollect ionBase.InternalRemoveAt(Int32
index) +17

Infragistics.WebUI.UltraWebGrid.ValueListItemsColl ection.RemoveAt(Int32
index) +68

Infragistics.WebUI.UltraWebGrid.ValueListItemsColl ection.System.Web.UI.IStateManager.LoadViewState(O bject
savedState) +317

Infragistics.WebUI.UltraWebGrid.ValueList.System.W eb.UI.IStateManager.LoadViewState(Object
savedState) +121

Infragistics.WebUI.UltraWebGrid.UltraGridColumn.Lo adViewState(Object
savedState) +203

Infragistics.WebUI.UltraWebGrid.UltraGridColumn.Sy stem.Web.UI.IStateManager.LoadViewState(Object
savedState) +11

Infragistics.WebUI.UltraWebGrid.ColumnsCollection. System.Web.UI.IStateManager.LoadViewState(Object
savedState) +1894

Infragistics.WebUI.UltraWebGrid.UltraGridBand.Syst em.Web.UI.IStateManager.LoadViewState(Object
savedState) +558

Infragistics.WebUI.UltraWebGrid.BandsCollection.Sy stem.Web.UI.IStateManager.LoadViewState(Object
savedState) +493

Infragistics.WebUI.UltraWebGrid.UltraGridLayout.Sy stem.Web.UI.IStateManager.LoadViewState(Object
savedState) +725
Infragistics.WebUI.UltraWebGrid.UltraWebGrid.LoadV iewState(Object
savedState) +118
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+186
System.Web.UI.Control.LoadChildViewStateByIndex(Ar rayList
childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+224
System.Web.UI.Control.LoadChildViewStateByIndex(Ar rayList
childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+224
System.Web.UI.Control.LoadChildViewStateByIndex(Ar rayList
childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+224
System.Web.UI.Control.LoadChildViewStateByIndex(Ar rayList
childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+224
System.Web.UI.Control.LoadChildViewStateByIndex(Ar rayList
childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+224
System.Web.UI.Control.LoadChildViewStateByIndex(Ar rayList
childState) +136
System.Web.UI.Control.LoadViewStateRecursive(Objec t savedState)
+224
System.Web.UI.Page.LoadAllState() +439
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+1092

Oct 20 '08 #1
0 1323

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Andrew MacIntyre | last post: by
1 post views Thread by Arben Kryeziu | last post: by
3 posts views Thread by Ken | last post: by
13 posts views Thread by Chameleon | last post: by
35 posts views Thread by erikwickstrom | last post: by
85 posts views Thread by Russ | last post: by
2 posts views Thread by Georgy Panterov | last post: by
1 post views Thread by Steffen Stellwag | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.