jQWidgets Forums
jQuery UI Widgets › Forums › General Discussions › Urgent Help: Stop running this script ???
Tagged: IE 8, jqgrid, jqxgrid, stop running this script
This topic contains 1 reply, has 2 voices, and was last updated by Peter Stoev 11 years, 1 month ago.
-
Author
-
Stop running this script. A script on this page is causing your web browser to run slowly. If it continues to run, your computer might become unresponsive.
Hi there, I am getting this error while binding large amount of a data to my jqxgrid using IE 8.
function calltest() { var boolRenderer = function( row, column, value ) { var html = "<div style='overflow: hidden; text-overflow: ellipsis; text-align: left; padding:4px 4px 2px 2px;"; if( value === true ) { if( column == "Exported" ) { html += "font-weight:bold;background-color:#99FF66;"; } else if( column == "HasErrors" ) { html += "font-weight:bold;background-color:#FF9999;"; } } html += "'>"; if( value === true ) { html += "Yes"; } else { html += "No"; } html += "</div>"; return html; }; var columns = [ { name: "ID", text: 'ID', datafield: 'ID', width: 55 }, { name: "TransactionItemID", text: 'Trans Item ID', datafield: 'TransactionItemID' }, { name: "Exported", text: 'Exported', datafield: 'Exported', cellsrenderer: boolRenderer }, { name: "HasErrors", text: 'Has Errors', datafield: "HasErrors", cellsrenderer: boolRenderer }, { name: "FirstName", text: 'First Name', datafield: 'FirstName', width: 110, type: "string" }, { name: "LastName", text: 'Last Name', datafield: 'LastName', width: 110, type: "string" }, { name: "DOB", text: 'DOB', datafield: 'DOB', width: 90, type: "string" }, { name: "IDNumber", text: 'ID Number', datafield: 'IDNumber', width: 110, type: "string" }, { name: "StreetAddress", text: 'Street Address', datafield: 'StreetAddress', width: 150, type: "string" }, { name: "City", text: 'City', datafield: 'City', width: 130, type: "string" }, { name: "State", text: 'State', datafield: 'State', width: 70, type: "string" }, { name: "Post", text: 'Post', datafield: 'PostalCode', width: 70, type: "string" }, { name: "Email", text: 'Email', datafield: 'Email', width: 150, type: "string" }, { name: "Created", text: 'Created', datafield: 'Created', width: 90, type: "string" }, { name: "Updated", text: 'Updated', datafield: 'Updated', width: 90, type: "string" }, { name: "ABN", text: 'ABN Number', datafield: 'ABN', width: 100, type: "string" }, { name: "CompanyName", text: 'Company Name', datafield: 'CompanyName', width: 100, type: "string" } ]; var t =0; var model = @Html.Raw( POSWebManager.MvcApplication.Serializer.Serialize( Model) ); @* var model2 = @Html.Raw( POSWebManager.MvcApplication.Serializer.Serialize( Model.Skip(100).Take(100) ) );*@ var adapter= new $.jqx.dataAdapter( { localdata: model, datatype: "json", datafields: columns } ); $("#jqxgrid").jqxGrid( { width: 960, source:adapter, theme: getDemoTheme(), hasThreeStates:false, pageable: true, autoheight: true, sortable: true, altrows: true, enabletooltips: true, showfilterrow: true, filterable: true, columnsresize: true, selectable: true, pagesize: 25, pagesizeoptions: ['25', '50', '100', '1000'], selectionmode: 'multiplerowsextended', columns: columns } ); //} }
$(document).ready(function () {
calltest();
} );I am new to jqgrids and i am using mvc3 asp.net, By user requirements i can not use windows registry key or Active X controls to solve this. Please help me out in this.
Thanks
DamanHi Daman,
Ok, if you want to load more data and your browser is not capable to load it, then that means that you should use Server Paging and load the data on demand instead of loading it all at once. Such sample is available online: http://www.jqwidgets.com/jquery-widgets-demo/demos/php/serverfiltering_paging_and_sorting.htm?arctic
Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.com -
AuthorPosts
You must be logged in to reply to this topic.