I think you're not understanding your own question, quite frankly.
Here's you're question:
I know without some pretty involved doing in Excel but curious if object model of OpenOffice supports?
Can you dynamically create code in openoffice?
For example: can you have a script that will create a NEW openoffice calc spreadsheet and then subsequently have code saved in it? Such as and OpenBook event where nextime someone opened it some other code would run?
The reason I mentioned LibreOffice is that it is highly possible you did not know about it. Since it's a new product, it's possible you would be referring to it rather than OpenOffice. Whichever you want to go with, however, I'd suggest you specify that one. So for the remainder of this thread, I'll just assume OpenOffice.
Now to break down the details:
==>I know without some pretty involved doing in Excel but curious if object model of OpenOffice supports?
1. That question is so grammatically incorrect, I can't begin to ensure I understand it. My
guess is you're asking 1 of 2 things:
1. Does OpenOffice support the MS Office Object Model? or..
2. Does OpenOffice have it's own built-in Object Model?
==>Can you dynamically create code in openoffice?
Make sure you understand the definition of dynamic code, and that you understand what you're asking here. If you think you understand what you're asking, please clarify.
One possible reference
==>
For example: can you have a script that will create a NEW openoffice calc spreadsheet and then subsequently have code saved in it? Such as and OpenBook event where nextime someone opened it some other code would run?
So, are you wanting to just click a button, and the program create it's own programmed scripting automatically? Or are you talking more-so about setting up the scripting the same/similar way you would do in Excel? In Excel, for instance, you would create the workbook (as of MS Office 2007, specifically an .xlsb workbook - macro enabled), put whatever code in it where you want, according to your need/desire, save it... then when opened (if in the workbook_open event), it would execute. Or if you wnated it to be a template, of course, you'd save that as a macro-enabled template.
Is
that what you're after? Where YOU set up the code, or are you looking for it to record the code like the macro recording tool in MS Office?
In OpenOffice, to record a macro:
For the On Open event, here's one reference I found:
Otherwise, you need to clarify your question.