I have an ASP.NET MVC page with jQuery Editable Datatable that has 14 columns. I have a (Apply No Findings) button to do snd client side calculations for all rows in this table.
When we click this button, after applying the calculations, for every 4 lines this "Stop Running Script" message is displayed.
I checked the settings. On the "Internet Options" tab, the "Advanced" tab, the option "Disable Script Debugging (Internet Explorer)" is checked. And "Display Notification of Script Error" is not marked.
I am using Internet Explorer 8. Now this does not happen in IE9. But this is a server, we cannot switch to IE9.
I researched and tried these two options, and nothing worked.
Example (1): http://www.codeproject.com/Tips/406739/Preventing-Stop-running-this-script-in-Browsers
Example (2): http://www.picnet.com.au/blogs/guido/post/2010/03/04/how-to-prevent-stop-running-this-script-message-in-browsers/
Anyone has this isse and any suggestions are highly appreciated.
This is the actual code that displays the message Script Message:
for(i < iTotalRecords;i++) { var row = oTableAuditLines.fnGetData(i); oTableAuditLines.fnUpdate("NF",i,1); UndoHCPCS(row,i); UndoHCPCSModCodes(row,i); UndoLineUnitCount(row,i); oTableAuditLines.fnUpdate("", i, 6);
Inverting the sample code example in example (2), I changed the code as shown below, and I still get the Script message:
// This Function Avoids Script Run
RepeatingOperation = function(op, yieldEveryIteration) { var count = 0; var instance = this; this.step = function(args) { if (++count >= yieldEveryIteration) { count = 0; setTimeout(function() { op(args); }, 1, []) return; } op(args); }; }; function ApplyNoFindings() { var i = 0; var ro = new RepeatingOperation(function() { var row = oTableAuditLines.fnGetData(i); oTableAuditLines.fnUpdate("NF",i,1); UndoHCPCS(row,i); UndoHCPCSModCodes(row,i); UndoLineUnitCount(row,i); oTableAuditLines.fnUpdate("", i, 6);
}
What am I doing wrong here?