This project is read-only.
1

Resolved

"Index was out of range" runtime error in ListSection

description

Hi,
 
When running build 7271 (the latest), I get an argument out of range exception (Index was out of range) when expanding or contracting a superlist section.
 
Excellent control! Very impressed so far. This bug is a bit of a show stopper though!
 
Exception Detail:
System.ArgumentOutOfRangeException was unhandled
Message="Index was out of range. Must be non-negative and less than the size of the collection.\r\nParameter name: index"
Source="mscorlib"
ParamName="index"
StackTrace:
   at System.ThrowHelper.ThrowArgumentOutOfRangeException(ExceptionArgument argument, ExceptionResource resource)
   at System.ThrowHelper.ThrowArgumentOutOfRangeException()
   at System.Collections.Generic.List`1.get_Item(Int32 index)
   at BinaryComponents.SuperList.Sections.ListSection.locateNearestRowThatsStillValid(PositionedRowIdentifier current, ItemList itemList, List`1 oldList)
   at BinaryComponents.SuperList.Sections.ListSection.CalculateListItems()
   at BinaryComponents.SuperList.Sections.ListSection.Layout(GraphicsSettings gs, Size maximumSize)
   at BinaryComponents.SuperList.SectionContainerControl.LazyUpdateTimerTick(Object sender, EventArgs e)
   at System.Windows.Forms.Timer.OnTick(EventArgs e)
   at System.Windows.Forms.Timer.TimerNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
   at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
   at System.Windows.Forms.Application.Run(Form mainForm)
   at SuperListTest.Program.Main() in C:\Code\Examples\Superlist\Main\Examples\QuickStartCSharp\Program.cs:line 32
   at System.AppDomain.nExecuteAssembly(Assembly assembly, String[] args)
   at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
   at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()
 
 
Cheers!

comments

Superstar wrote Sep 26, 2007 at 12:31 AM

I think it was caused by your last fix:

"2. Fixing an issue where collapsing a group via the groups '-' icon where a sub item was selected caused the selection to switch to the next group rather than the collapsed one."

wrote Sep 26, 2007 at 11:11 AM

Yep I've just checked in a fix.

wrote Feb 14, 2013 at 3:28 AM

wrote May 16, 2013 at 8:44 AM

wrote May 16, 2013 at 8:44 AM

wrote Jun 14, 2013 at 7:51 AM