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 5943635
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T16:25:25+00:00 2026-05-22T16:25:25+00:00

Is there any way to force jqGrid not to remove the subgrid data when

  • 0

Is there any way to force jqGrid not to remove the subgrid data when its row is toggled? My current process for loading the datagrid is as follows:

1) Setup main grid, setting subgrid up programatically with an ID that I can use later

2) Load data into main grid locally via json

3) Add data to subgrid locally via json

Due to the fact that I am loading the subgrid locally instead of by a URL when the user toggles (hides then redisplays) the grid doesn’t have any data in it and I want it to display the original data that was provided to the subgrid.

I know that this may seem like a weird way of loading the data, but there is a reason

What I am currenty doing with jqGrid is displaying tons and tons of insurance information on a single web page (essentially it is a report). This web page should load all of the data automatically and I have many instances where I need to provide subgrid functionality. I have figured out how I can do this by manually forcing the click event to occur so that the subgrid will be displayed, but again, if the user clicks on the subgrid then it disappears and doesn’t come back.

If you have any suggestions for this please let me know.

Also, if you think there are better ways of getting all of the data to display automaticaly please let me know that as well. So far I have found jqGrid to be easy to work with, but I have been forcing it to do things that it didn’t natively do, like adding total values in the footer row.

Thank you in advance for your assistance.

  • 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-22T16:25:26+00:00Added an answer on May 22, 2026 at 4:25 pm

    What you want to do is to prevent jqGrid from reloading subgrid data when a row is expanded. The control knob for this is in the subGridOptions property of the jqGrid. The subGridOptions object has a boolean property called reloadOnExpand which controls this exact behavior.

    When you initialize your jqGrid object, just make sure to set this property to false, as below:

    jQuery("#gridId").jqGrid({
        // ... other properties ...
        subGrid: true,
        subGridOptions: {
            reloadOnExpand: false // Prevent jqGrid from wiping out the subgrid data.
        },
        subGridRowExpanded: subGridExpandCallback,
        // ... other properties ...
    

    The only place I could find this code was by doing a “View Source” on the page at their demo site that mentions this behavior. The demo page at the time of this posting is here: http://www.trirand.com/blog/phpjqgrid/examples/hierarchy/subgrid_loadonce/default.php

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any way to force Flex to draw empty PieChart when all data
Is there any way to force Maven to use remote artifacts and not those
Is there any way to force a listview control to treat all clicks as
Is there any way to force an update of software using RunOnce, without having
Is there any way to force Outlook to display HTML in the desktop alert
Is there any way to force Text-Mate to use a two-space tab instead of
Is there any way to force PHP to blow up (error, whatever) if I
Is there any way to force Visual Studio to copy selected code to the
Is there any way to force a Route to be executed, only if all
Is there any way to force a browser to refresh or empty it's cache,

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.