Hi Team
is there any possibilities like if filter is applied on grid, export only filtered data if at all data is distributed in 5 pages.
for example in 8000 data if 3000 is filtered data export all 3000 data only.
Thanks
Hi,
Thank you for posting in the Infragistics community !
To export only the filetred rows you need to specify filteredRowsOnly value to the filtering option, as follows:
$.ig.GridExcelExporter.export($("#grid"), { fileName: "igGrid", gridFeatureOptions: { "filtering": "filteredRowsOnly" } });
Please see the attached sample and let me know if you have further questions on the matter, I will be glad to help.
Hi Hristo
Thanks for your reply i will checked that and will let you know meanwhile I have another issue can you please help me on this its very urgent.
we are using your licensed version and recently updated to 2015.1 version for using export to excel feature of infragistics.
we are facing one problem we have one column where we are using formatter. In export to excel we are exporting allrows what problem we are seeing in exported excel the columns which has formatter only export data for current page. while debugging we saw in cellExporting event after current page no of rows the data is coming as blank.
Could you please help me on this its stopping our client deliverable.
Prakash
Thanks Hristo
if any Quick Fix that will also work fro me time being. eagerly waiting for your reply.
Actually this is fixed in the latest version of 15.1, which is available for you to download at Infragistics website. After you download and install it issue will be fixed. I am also attaching my sample using cdn references to the latest version of 15.1, which is 15.1.20151.2112. The grid has a column that uses a formatter function and paging as your described scenario.
You will see that exporting properly gets the data for the column using a formatter function.
Please review it and let me know if you have further questions on the matter.
Hi
Thats work for me thanks for your help and quick reply.
in cellExporting event is there is possibilities to set args.cellValue when i am trying to do args.cellValue=2.33 its still exporting the original data
Note: that cell also has for-matter function attached.
looking for your response.
args.setValue actually changes the value that is going to be exported to the sheet. So 2.33 is the original value, how do you want it to be formatted, and what is the formatter function you use ?
Please let me know and I will see if there is an issue
I replied in this forum thread
I am elaborating my point.
actually what we are doing according to our client has business requirement that they want to see percentage value some times with two decimal value sometimes 3 sometimes and sometimes with n.
since infragistic has max/min decimal value 2 for percent format default. so that we are achieving this by column formatter, where we restrict the number to display as desired number of decimals while creating column and its working perfectly, but now we are trying to export excel data, the problem occurring that the percentage value while exporting coming as '2.33%' string and exporting on excel cell whose type is number due to that its exporting data on cell with error says string is stored in number cells.
for that solution what i am thinking the cells value which is going to export to convert into float and set that cells format to percent.
something like this...
cellExporting: function (sender, args) { var filteredColumn = $.grep(sender._columnsToExport, function (v) { return v.hidden == false && v.key == args.columnKey }); if (filteredColumn.length > 0) { var format = filteredColumn[0].format; if (format == 'currency') { args.xlRow.getCellFormat(args.columnIndex).formatString('$#,##0.00_);[Red]($#,##0.00)'); } if (typeof (args.cellValue) == "string" && args.cellValue.contains('%')) { args.cellValue=parseFloat(args.cellValue); args.xlRow.getCellFormat(args.columnIndex).formatString('0.00%'); } }},
but unfortunatly its not setting the parsed value to cellValue, How i can achieve this. or there any better solution we have.
that actually not working for me args.setValue in cell exporting event is coming as undefined.
may be i am missing some thing can you please help me on that.
Hi Hiristo
actually what we are doing our client has business requirement like our client want to display percentage value some times with two decimal value sometimes 3 sometimes n.
since infragistic has max/min decimal value 2 for percent format default that we are achieving by formatter where we restrict the number to display as desired number of decimals its working but now we are trying to export excel data the percentage value is string on cell whose type is number due to that its exporting data on cell with error says string is stored in number cells.
cellExporting: function (sender, args) { var filteredColumn = $.grep(sender._columnsToExport, function (v) { return v.hidden == false && v.key == args.columnKey }); if (filteredColumn.length > 0) { var format = filteredColumn[0].format; if (format == 'currency') { args.xlRow.getCellFormat(args.columnIndex).formatString('$#,##0.00_);[Red]($#,##0.00)'); } if (typeof (args.cellValue) == "string" && args.cellValue.contains('%')) { //args.cellValue=parseFloat(args.cellValue); args.cellValue = 2.33; args.xlRow.getCellFormat(args.columnIndex).formatString('0.00%'); } } },
do you have any better solution for me it will be very helpful