Author Topic: Problem after export to Excel  (Read 3518 times)

TonyLeech

  • Pro Enterprise
  • Jr. Member
  • *
  • Posts: 76
    • View Profile
Problem after export to Excel
« on: April 07, 2017, 02:02:53 am »
After exporting a grid to Excel (version 3.3.2) the Excel file opens up ok with the correct columns and all my data.  The data is all in a single Excel worksheet tab and there are no other tabs.  When I click to add a new tab I get the following error message in Excel "That command cannot be used on multiple selections."

Can you confirm that you observe the same issue?  If so, do you know why it is doing that?  Google suggests that there is corruption in the file, but I have not modified the file since it was exported from ParamGrid.

This is the code I use to export the Excel file...

Code: [Select]
{ type: 'separator' },
{
type: 'select',
label: 'Format: ',               
attr: 'id="export_format"',
options: [{ xlsx: 'Excel', csv: 'Csv', htm: 'Html', json: 'Json'}]
},
{
type: 'button',
label: "Export",
icon: 'ui-icon-arrowthickstop-1-s',
listener: function () {
pageModel.type = 'local';
this.option( "pageModel", pageModel);
this.refreshDataAndView();
this.one('load', function() {
var format = $("#export_format").val(),                           
blob = this.exportData({
//url: "/pro/demos/exportData",
format: format,                               
render: true
});
if(typeof blob === "string"){                           
blob = new Blob([blob]);
}
saveAs(blob, "Transactions."+ format );
pageModel.type = pageModelType;
this.option( "pageModel", pageModel);
this.refreshDataAndView();
});
}
},

Many thanks for your assistance.

Tony

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6173
    • View Profile
Re: Problem after export to Excel
« Reply #1 on: April 07, 2017, 04:28:24 pm »
Tony

I also observe the same issue. I'm moving it to the bug log, would let you know once the fix is available.

Thanks for reporting the issue.

TonyLeech

  • Pro Enterprise
  • Jr. Member
  • *
  • Posts: 76
    • View Profile
Re: Problem after export to Excel
« Reply #2 on: April 16, 2017, 05:04:51 pm »
Thanks for your confirmation of the bug.

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6173
    • View Profile
Re: Problem after export to Excel
« Reply #3 on: June 26, 2017, 06:23:55 pm »
This is fixed in v3.4.1