BugNET

Open source issue tracking & project management
| Login

Import Update!

We are currently in transition and have moved our discussions to CodePlex. These forums will remain as reference until we launch of our new site in the upcoming weeks. After that they will be removed.

Thank you for your patience during our transition.

Forums

HomeHomeDevelopment and...Development and...General Develop...General Develop...Changing number of issues viewed -> Index was out or rangeChanging number of issues viewed -> Index was out or range
Previous
 
Next
New Post
2/2/2012 6:45 AM
 
Hi,

Just recently (after 24+ issues) I suddenly started to get an index out of range error.

To reproduce this problem I would:
1) Log into bugnet
2) I view all my open issues (default view 10 issues per page)
3) I go back to the main screen
4) I view all my open issues again (change default view to anything but 10)
5) I go back to the main screen
6) I click any link that would list issues and an error is generated:

System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.  Parameter name: index     at System.Collections.Generic.List`1.get_Item(Int32 index)     at BugNET.UserControls.DisplayIssues.InsertCustomFieldData()     at BugNET.Issues.IssueList.BindIssues()     at BugNET.Issues.IssueList.Page_Load(Object sender, EventArgs e)     at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e)     at BugNET.UserInterfaceLayer.BasePage.OnLoad(EventArgs e)     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)     at System.Web.UI.Page.HandleError(Exception e)     at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)     at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)     at System.Web.UI.Page.ProcessRequest()     at System.Web.UI.Page.ProcessRequest(HttpContext context)     at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()     at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
 
New Post
2/2/2012 1:47 PM
 
This is a known issue and a new release will be out this weekend to fix the issue.
Thanks.

Davin Dubeau

follow us on twitter facebook users group google plus
 
New Post
2/6/2012 12:20 PM
 
I am having the same issues that PJ has experienced. I updated to the latest release today (.9.152) and it seems like the issue still remains.
 
New Post
2/6/2012 2:02 PM
 
It appears the issue is on DisplayIssues.ascx.cs.

For the page level variable declared at the top of the user control (line 34):

//stores total amount of columns (fixed and custom)
private int nrColumns = FixedColumns;

This is being set to the FixedColumns number (22) on load. However, the DataBind() for this page is occurring twice after you set a page size if you refresh the page or click a link that takes you to an issue list. This causes the columns to be added twice. The error will not occur immediately after setting the page size. You must completely reload and not postback. I've commented out the page declaration for nrColumns and moved this down to before the check on whether to add costum columns. (~ lines 124-126).

int nrColumns = FixedColumns;
//checks if its initial load to add custom controls and checkboxes
if (gvIssues.Columns.Count <= nrColumns + 1)

This appears to be working correctly.
 
New Post
2/7/2012 12:13 PM
 
Thanks Heaps Jesse. That fix looks like it does the job.
 
Previous
 
Next
HomeHomeDevelopment and...Development and...General Develop...General Develop...Changing number of issues viewed -> Index was out or rangeChanging number of issues viewed -> Index was out or range


Forum Policy

These Discussion Forums are dedicated to the discussion of the BugNET issue tracker.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:
1. No Advertising.
2. No Flaming or Trolling.
3. No Profanity, Racism, or Prejudice.
4. Site Moderators have the final word on approving/removing a thread or post or comment.
5. English language posting only, please.