Forum



11:26

26/05/2011

Hi,
starting from the working example listed in the Jqgrid Demos Advanced->Grid as Subgrid and actually copied it for this test, how to add a custom button?
It's hours I'm trying with different combinations but I'm not able to place a custom button in the Top Pager.
I can succesfully add a custom botton in the main grid, but I'm not able to reference the Top Pager for the Subgrid.
How to refer to inside grid correctly?
I'm using really as code base the Example in the Grid
Thanks
My code (last attempts copy&paste....there are many attempts):
//remove pager button from TOP (WORKING)
var topPagerDiv = $('#' + subgrid_table_id + '_toppager')[0];
$("#" + subgrid_table_id + "_toppager_center", topPagerDiv).remove();
$(".ui-paging-info", topPagerDiv).remove();
//NOT WORKING
$('#' + subgrid_table_id).jqGrid('navButtonAdd', topPagerDiv + '_left', {
caption: "Print Grid",
buttonicon: 'ui-icon-print',
position:"last",
onClickButton: function() {
print_grid();
}
});
11:38

26/05/2011

In the example I can see the following code:
If I try to enable any feature like Add (add:true) there is no difference in the Top pager...so even the example is not referring correctly to the topbar, please how this can be done clearly?
Thanks
20:38

26/05/2011

Please, someone take the example Advanced->Grid as Subgrid and try a simple copy&paste.
In the example page I can see the following code:
If I need to enable the Add button to the Bar I expect to write:
But if you try yourself you will find that it doesn't work...
My question is: how to work on the top bar for a subgrid?
Thanks
Most Users Ever Online: 715
Currently Online:
171 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