Application Error - Index is either negative or above row count

I am receiving the below when I go to save any Lines above 1 on a customized SO Entry screen. The below is from the saving of Line 7 on the Order. The Order does save but the below error appears the number of times of the Index in the Error Message. If anyone could provide some guidance on what I need to do to correct that would great. The customization code is quite lengthy so I didn’t want to include at this time.

Application Error

Exception caught in: System.Data

_Error Detail _
**============**
Message: Index 6 is either negative or above rows count.
Program: System.Data.dll
Method: GetRow

_Client Stack Trace _
**==================**
** at System.Data.DataView.GetRow(Int32 index)**
** at Ice.Lib.Framework.EpiUltraCombo.SetActiveRow(Int32 dataviewRowIndex)**
** at Ice.Lib.Framework.EpiUltraCombo.DataRow_Notify(EpiDataView view, EpiNotifyArgs ar)**
** at Ice.Lib.Framework.EpiViewNotification.Invoke(EpiDataView view, EpiNotifyArgs args)**
** at Ice.Lib.Framework.EpiDataView.OnEpiViewNotification(EpiNotifyArgs e)**
** at Ice.Lib.Framework.EpiDataView.Notify(EpiNotifyArgs args)**
** at Ice.Lib.Framework.EpiTransaction.NotifyAllOthers(EpiDataView sourceView, Boolean changeGridPropsCurrentRowOnly, Boolean notifyTree, Guid notifyId)**
** at Ice.Lib.Framework.EpiDataView.Notify(EpiNotifyArgs args)**
** at Ice.Lib.Framework.EpiDataView.SetChildFilterAndNotifyChildViewWhenHasCurrentRow(EpiDataView childView, EpiNotifyArgs args, Boolean forceIt)**
** at Ice.Lib.Framework.EpiDataView.SetChildFiltersAndNotifyChildViews(EpiNotifyArgs args, Boolean forceIt)**
** at Ice.Lib.Framework.EpiDataView.Notify(EpiNotifyArgs args)**
** at Ice.Lib.Framework.EpiDataView.SetChildFilterAndNotifyChildViewWhenHasCurrentRow(EpiDataView childView, EpiNotifyArgs args, Boolean forceIt)**
** at Ice.Lib.Framework.EpiDataView.SetChildFiltersAndNotifyChildViews(EpiNotifyArgs args, Boolean forceIt)**
** at Ice.Lib.Framework.EpiDataView.Notify(EpiNotifyArgs args)**
** at Ice.Lib.Framework.EpiTransaction.NotifyAll()**
** at Erp.UI.App.SalesOrderEntry.Transaction.Update()**

In my limited experience the error is really saying that you are trying to reference outside the bounds of the list/array. By the looks of the error it is trying to do this every time and orderline is being retrieved via the get row method.

It might sound silly, but I tend to forget how to code, because I don’t bathe myself in it every day. So when I come across an error I don’t fully understand. I take the following approach.

  1. Do a quick e10 search for the generic error to see what other responses have been when a “similar error” has been struck.
  2. Do a wider Google search (normally takes me to sites like stackoverflow).
    Once I have an understanding. I’ll fire up the customization in debug mode with Visual Studio and put a break point in and then run through and replicate the steps that generated the error.

Then if all else fails I throw myself at the mercy of the E10 community.

I know it sounds laborious, but that’s the joys of being the Epicor admin in a small company, you have to use many hats. You tend to know a little about a lot, and you only look at the detail when you have to.

Apologies I can’t give more help, but I hope my suggestions do.

1 Like

Does this happen to all users?

Have you tried it with a user with no Personalizations on the form? I’ve seen errors like this for personalizations.

Does your customization test for no data, clears datasets between calls, etc?