After upgrading to SC 9 and migrating an app from V8, When I scroll down in a grid with infinite scroll enabled , I get the following Ajax error: [TABLE=“class: scErrorTable, align: center, cellpadding: 0, cellspacing: 0, width: 1, height: 30”]
[TR]
[TD=“class: scErrorTitle, align: left”]Error[/TD]
[/TR]
[TR]
[TD=“class: scErrorMessage, align: center”]Undefined offset: 13[/TD]
[/TR]
[/TABLE]
On closer inspection (turned off ajax errors for the app) it gave me the actual line the error occurs in:
Error
Undefined offset: 13
Script: /var/www/html/myapp/_lib/lib/php/nm_data.class.php (750)
I do not know if this is because I have code in the OnRecord event, but nonetheless here is the lines that give the error,
(THIS IS SCRIPTCASE CODE, NOT MINE)
Here is Lines 750 to 758:
if ($dias != 0 && $dias == $dias_meses[$mes_1 + 1])
{
$dias = 0;
$meses++;
if ($meses == 12)
{
$meses = 0;
$anos++;
}
In my opinion this is a bug introduced in version 9 and should therefore be investigated by Netmake.
EDIT
This bug was also reproduced in a paginated Grid, the only thing they have in common is that they have advanced search enabled and custom code in the OnRecord Event.