Forum
Topic RSS
09:15
29/01/2010
OfflineHi all
I want to reload the grid when I clicked a button. But it doesnot reload data from server…and I got no javascript error with IE6.
Code:
$("#btn_delete").click(function() {
jQuery("#gridlist").jqGrid('setGridParam',{url:'http://192.168.244.93/test/xml.....p'}).trigger("reloadGrid");
});
I write it in another way , but it doesnot request data from server at all.
$("#btn_delete").click(function() {
$("#gridlist").setGridParam({page:1}).trigger("reloadGrid");
});
Loaded js libs are:
<script src="js/jquery.min.js" type="text/javascript"></script>
<script src="js/jquery-ui.min.js" type="text/javascript"></script>
<script src="js/i18n/grid.locale-jp.js" type="text/javascript"></script>
<script src="js/jquery.jqGrid.min.js" type="text/javascript"></script>
<script src="js/ajaxupload.js" type="text/javascript"></script>
By the way, SEARCH button and RELOAD button on the pager does not reload the grid , too...
Can anyone help me ? Thank you!
00:14
15/07/2011
Offline23:12
15/07/2011
OfflineWell, in case someone ever end up on this thread by a google search (as I did), I could'nt make the client side sort work after having added a filter to the list...
Apparently, you have to sort on server side if you remove the "loadonce: true,"
To do this, just add the folowing parameters to your ActionResult function: string sortField, string sortOrder
It automatically recieve the name of the column to sort by in sortField and the direction of the sort (asc or desc) in sortOrder...
It's slower than client side sorting, but it does it!
Most Users Ever Online: 994
Currently Online:
17 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
Log In
Home