Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6046057
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T07:11:41+00:00 2026-05-23T07:11:41+00:00

I am having bad performance with jqGrid when it loads more than 100 rows.

  • 0

I am having bad performance with jqGrid when it loads more than 100 rows. Below is the code I am using for ospatches data from my xml. How can i use data option of jqGrid in this context to make it a bit faster?

var ospatches=[];

$(xml).find('patch').each(function(){ 
var row={};
row.name=$(this).attr('name');
ospatches.push(row);
    });


$('#detailTable').empty();
$('<div width="100%">')
.attr('id','ospatchesSpan')
.html('<div class="titleBlue">Configuration&gt;System&gt;Os Patches</div>'+
    '<table id="list1" width="100%"></table>'+
    '<div id="gridpager"></div>'+
'</div>')        
.appendTo('#detailTable');    



jQuery("#list1").jqGrid({
datatype: "clientSide",
height: 250,
   colNames:['Name'],
   colModel:[
       {name:'name',index:'name', align:"right"},

   ],
   pagination:true,
   pager : '#gridpager',
   rowNum:10,
   scrollOffset:0,
   height: 'auto',
   autowidth:true,
viewrecords: true,
gridview: true,
edit:false,
add:false,
del:false

});



for(var i=0;i<ospatches.length;i++)
jQuery("#list1").jqGrid('addRowData',i+1,ospatches[i]);

jQuery("#list1").setGridParam({rowNum:10}).trigger("reloadGrid");
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T07:11:42+00:00Added an answer on May 23, 2026 at 7:11 am

    I wrote you before about the advantages of the usage data parameter, but probably you are new in the subject and not full understand what I mean. So I made the demo for you. It uses the data which you posted in your previous question. You can see that the 395 rows of data are loaded immediately. You can choose combobox in the pager to display all the rows at once and you will see that performance is very good.

    Moreover I wrote you before that you can simplify your code which recreate the contain of the $('#detailTable') div. In the demo I used just $("#list1").jqGrid('GridUnload') instead.

    I include the code of the example below:

    $('#reload').click(function(){
        $.ajax({
            url:'ospatches.xml',
            dataType:'xml',
            success: function(xml) {
                var ospatches=[];
                $(xml).find('patch').each(function(){
                    var row={};
                    row.name=$(this).attr('name');
                    ospatches.push(row);
                });
    
                $("#list1").jqGrid('GridUnload');
    
                $("#list1").jqGrid({
                    datatype: 'local',
                    data: ospatches,
                    colNames:['Name'],
                    colModel:[
                        {name:'name',index:'name', align:"right"}
                    ],
                    pager: '#gridpager',
                    rowNum:10,
                    rowList:[10,100,1000],
                    height: 'auto',
                    width: 500,
                    viewrecords: true,
                    gridview: true
                });
            }
        });
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just heard one of the clients having really bad performance on IE6 despite
this code is part of NBuilder . I'm having a bad day .. and
Maybe I'm having a bad day, but I can't seem to combine these 2
I am having a really bad issue where no matter what I try, the
Maybe I'm having a really bad day, but could someone possibly help me to
Is having tags inside a jstl tag considered bad form? So for example I
I know that having diamond inheritance is considered bad practice. However, I have 2
I know I'm doing this a bad way... but I'm having trouble seeing any
I am having bad times to generate a rdlc report to show report in
A user of my app out in the field seems to having bad crash-at-app-start

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.