Forum



02:03

01/09/2010

I'm having a problem where I set the data in a cell (that works fine) and then sort the grid. For some reason when I sort the grid the data in the cell reverts back to what it was before I called setCell. This worked fine prior to jqgrid 3.7, so I believe it is an issue that was introduced as part of the local changes.
My guess is that there is an internal array jqgrid maintains to do local sorting. When I call setCell, the grid is updated, but the internal array is not updated. When the sort happens it works with the internal array which resets the cell's data.
Does that sound right? Is there a way to update the internal array (if there is an internal array)?
$("#myGrid").jqGrid('setCell', rowId, 'typesort', data.TYPESORT, '', {title: ''});
$("#myGrid").jqGrid('setGridParam', {datatype:'local'});
$("#myGrid").jqGrid('sortGrid', 'framesort', true);
17:29

10/08/2009

You should always post a code example or a link which can be used to reproduce your problem. Without this it's very difficult to help you. Moreover If you write only some lines of code you suppose that only this lines are important to fix your problem. In reality it is not seldom that the problem will be somewhere else where you don't suppose at the beginning. For example, such "unimportant" things like !DOCTYPE, versions of jQuery UI, other JavaScript files of the order of JS-files and so on can sometime be the reason of very strange effects. Moreover it's always more "informative" to eat a piece of cake as to read a text which describe its taste.
Regards
Oleg
Most Users Ever Online: 715
Currently Online:
55 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66