Jqgrid - Uncaught Rangeerror: Maximum Call Stack Size Exceeded
Solution 1:
The code which you posted is wrong, but I'm sure that you have other place of your code which is the origin of long title
and long cell content.
The main error in the code which you posted: you should don't make binding to the grid inside of loadComplete
. loadComplete
will be executed multiple times. On every execution you add one more binding, which is wrong. Instead of that you should move $("#grid").on("jqGridAfterLoadComplete jqGridRemapColumns", function () {...});
and set it before creating the grid. You should understand that jqGridAfterLoadComplete
is event which will be triggered before loadComplete
every time. I suppose that you produces recursion in some way.
I would strictly recommend you to migrate to free jGrid (see here) or at least to use autoWidthColumns
method which I published in jQuery.jqGrid.autoWidthColumns.js
(see here). See the answer for more information and the old demo. What you will need is just to use $("#grid").jqGrid("autoWidthColumns");
before creating the grid. All required bindings ($("#grid").on("jqGridAfterLoadComplete jqGridRemapColumns", function () {...});
) do the method autoWidthColumns
internally.
Post a Comment for "Jqgrid - Uncaught Rangeerror: Maximum Call Stack Size Exceeded"