excel forumula calculation when spreadsheet opens
excel forumula calculation when spreadsheet opens

I was playing with functions and hyper links in tables and trying to export them to excel.
I came across this question: https://datatables.net/forums/discussion/42097
that lead me to try to find how to get them to auto evaluate.
it occurred to me that in python I'm using XLSXwritter and the forumals work there, so what are they doing?
I found this tidbit:
that lead me to this: https://stackoverflow.com/questions/18355691/set-xlsx-to-recalculate-formulae-on-open
the good part is this:
so the question is do you set
<calcPr fullCalcOnLoad="1"/>
Replies
I don't see that property in xl/workbook.xml. You can view the spreadsheet XML by unzipping the file the download XLSX file. I created a simple export that uses
SUM()
in one of the columns. TheSUM()
function executes when opening the exported file.https://live.datatables.net/ninukebu/1/edit
I don't have Excel but opened it in Numbers on the Mac. Does the function automatically execute for you in Excel?
I updated the test case to add
<calcPr fullCalcOnLoad="1"/>
to theworkbook
node in xl/workbook.xml. Not sure if that is the correct place. Does this do what you want?https://live.datatables.net/rahipuvo/1/edit
Kevin
Yup, as always, Kevin is spot on. The answer is no, I don't set
fullCalcOnLoad
at all. You can see the general XML structure for the spreadsheet that is created here.Allan