Hey Folks… First let me apologize for not contributing much here… I do check in at least once a week but all the questions are over my head as a noob (and I don’t take blind stabs at things like people in other forums. I’m of the position of : If I don’t know I don’t speak and confuse the situation)…
That aside… I could really use some help with a Very basic HTML to Excel (.xlsx) download
Looking at some examples, I do have one that I did more in. I do remember having problems with FormatColumns(). I just had to edit the dataformat string to something POI could understand. Here is a small example.
Looks like CFSpreadSheet IS supported in Lucee in Script ( the Lucee Docs indicate the Tag is not supported. Must be script only and I’m good with that for sure )
Result is : test.xls - Opens in Excel with out error
.
.
.
I’m working on pushing straight to the browser for Download : Not working with or without conversion to binary ( where as reading file as binary does work)
You’ll find plenty of examples in the documentation: every single method has at least one. I’m happy to provide any specific examples if you can’t find what you’re after.
Lucee doesn’t provide any spreadsheet functionality out of the box, but you can use the Spreadsheet Library or the Extension (which supports the ACF syntax including tags), depending on your needs.
Check out the downloadFileFromQuery() method which will convert a query into a downloadable spreadsheet in one line of code.
If you’re not invested in Excel and simplicity is your goal, this example might help. We often make raw data from our system available as a CSV file download, which clients can open in their default spreadsheet tool. Don’t forget to remove any unwanted commas from your data.