pauls
11/01/2022, 3:09 PMMyka Forrest
11/01/2022, 3:13 PMMichael Schmidt
11/01/2022, 3:29 PMpauls
11/01/2022, 3:34 PMMichael Schmidt
11/01/2022, 3:35 PMMichael Schmidt
11/01/2022, 3:38 PM<cfcontent type="application/vnd.ms-excel" reset="true">
<cfheader name="Content-Disposition" value="attachment; filename=report#GetTicKCount()#.xls">
pauls
11/01/2022, 3:39 PMcfsimplicity
11/01/2022, 3:40 PMpauls
11/01/2022, 3:43 PMcfsimplicity
11/01/2022, 3:45 PMpauls
11/01/2022, 3:49 PMcfsimplicity
11/01/2022, 3:58 PMcfsimplicity
11/01/2022, 4:15 PMwb = SpreadsheetNew( "test", true );
SpreadsheetAddRow( wb, "one,two" );
bin = SpreadsheetReadBinary( wb );
cfheader( name="Content-Disposition", value='attachment; filename="test.xlsx"' );
cfcontent( type="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", variable="#bin#", reset="true" );
pauls
11/01/2022, 4:18 PMJim Frankowski
11/01/2022, 4:26 PMpauls
11/01/2022, 4:45 PMcfsimplicity
11/01/2022, 4:49 PMattachment
content-disposition suggests not launching an application to open it, just downloading the file. But it will depend on your browser's mime handling config, i.e. what the browser is set to do with an .xlsx file.pauls
11/01/2022, 5:20 PMpauls
11/01/2022, 5:25 PM