hi,
 i am using filter tool bar on export to excel
$(“#list”).jqGrid(‘filterToolbar’, { stringResult: true, searchOnEnter: true, defaultSearch: “cn” }).navButtonAdd(‘#pager’, {
caption:“Export to Excel”,
buttonicon:“ui-icon-disk”,
onClickButton:function() {ExportDataToExcel(“#list”);},
position:“last”});
Â
function ExportDataToExcel(tableCtrl) {
ExportJQGridDataToExcel(tableCtrl,
“sample.xlsx”);
}
Â
This is my ExportJQGridDataToExcel function.
Â
function
ExportJQGridDataToExcel(tableCtrl, excelFilename) {
var allJQGridData = $(tableCtrl).jqGrid(‘getRowData’);
var jqgridRowIDs = $(tableCtrl).getDataIDs();
var headerData = $(tableCtrl).getRowData(jqgridRowIDs[0]);
Â
when i use this
var allJQGridData = $(tableCtrl).jqGrid(‘getGridParam’, ‘data’);Â it will give all the records in the grid
when i use this
var allJQGridData = $(tableCtrl).jqGrid(‘getRowData’); it will give the filtered records and only first page is capturing.
Â
Can any one plz help me out how to solve this issue,How can i get all the records in the grid as well as when i filter i need to get selected records.
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top