I have some hidden columns in my grid, I want to export these columns too by using exportdata.
Please tell me how to do it as soon as possible.
Thanks & Regards,
You can achieve this by setting the fifth parameter of exportdata to true. Here is more information from the API Documentation:
The first parameter of the export method determines the export’s type – ‘xls’, ‘xml’, ‘html’, ‘json’, ‘tsv’ or ‘csv’.
The second parameter is the file’s name. If you don’t provide a file name, the Grid will export the data to a local variable.
var data = $(“#jqxgrid”).jqxGrid(‘exportdata’, ‘json’);
The third parameter is optional and determines whether to export the column’s header or not. Acceptable values are – true and false. By default, the exporter exports the columns header.
The fourth parameter is optional and determines the array of rows to be exported. By default all rows are exported. Set null, if you want all rows to be exported.
The fifth parameter is optional and determines whether to export hidden columns. Acceptable values are – true and false. By default, the exporter does not export the hidden columns.
The sixth parameter is optional and determines the url of the export server. By default, the exporter is hosted on a jQWidgets server.
The last parameter is optional and determines the char set.
Thanks for your response.
Can you please tell me how i can customize this generated excel .I want to format this excel according to me.
Please guide me regarding this as soon as possible.
Thanks & Regards,
The only way to do this is to customize your grid and then export to Excel.
I have the same problem with jqgrid. I need to include the hidden columns of jqgrid when I export to excel. Give me some suggestions how can I handle it. By default Hidden columns are not visible in excel.
The method used by me is
title: ‘DetDem Details’,
- This reply was modified 3 years, 10 months ago by Benazir.
There is a slight difference between the jqxGrid and jqxDataTable.
Could you clarify it, which widget do you use?
In each one column, you could include the
exportablemember which determines to be exported or not.
Please, check your columns.
You must be logged in to reply to this topic.