views:

98

answers:

3

Hi, i want to create an excel file with coldfustion. since today, i was saving a file AS an html AND changing the extension.

i need to create now a real excel file. some advise? thanks

+5  A: 

Got ColdFusion 9? It is baked in with the cfspreadhseet tag (and related functions).

CF Jedi Master
no, am using colfusion 8
stunaz
+5  A: 

Or else you can use Ben Nadel's POI utility. It's pretty simple. We've been using it for years to make spreadsheets with multiple worksheets.

http://www.bennadel.com/projects/poi-utility.htm

Jason Tabler
..and it should work with most CF versions (I believe MX7+)
Leigh
it seems compllicated
stunaz
Everything seems complicated at first when it comes to programming with other people's code. However, the light will shine through if you spend even 30 minutes with the POI utility.
Jason Tabler
+1  A: 

Depending on the complexity of the sheet you could just generate the XML for a xlsx file in a bunch of nested cfloops. Export a sheet as XML and take a look.

WaldenL
I did it this was with a .NET winforms app once. Quite frankly, this is the quickest way to do it. As long as you xml escape all the text you should be fine. Its likely this method will perform better than any other solution as well.
Justin Dearing