Known Participant
August 30, 2024
Question
Error while exporting to excel - File format and extension doesn't match
- August 30, 2024
- 2 replies
- 1871 views
Hi,
I have the below code to generate output to excel. But when i open the excel after downloading, it shows that "file format and extension doesn't match". Please refer the screenshot and generated excel attached.
<cfheader name="content-disposition" VALUE="attachment; filename=sitereport.xls">
<cfset type="application/msexcel">
Is it because it is .xls file and I am opening in office 365 enterprise (where the extension should be .xlsx)? Attached the excel file also for reference.
regards,
Sunil
