Re: Generating spreadsheet from a script



John McNamara wrote:
At 11:29 09/12/02 +0100, you wrote:

I have then been asked to do it for different clients, and here is where
my heartache ;-) begins... Instead of having a different template for
each client (a real pain), I want to dynamically generate the
spreadsheet, using something like Perl or Python would be great.

I would also love to be able to graph the results, but that is probably
a second step that should be dealed with later.



One possibility is to use the Spreadsheet::WriteExcel Perl module.

This will allow you to dynamically generate Excel files on a Unix platform.

See:
    http://freshmeat.net/projects/writeexcel/
    http://search.cpan.org/search?dist=Spreadsheet-WriteExcel

It doesn't support graphs however.


Also, in conjunction with Jody, I hope to start work soon on a Perl interface to Gnumeric via libgnumeric.

John.
--




I'm using a python plugin to do exactly the opposite operation... works ok for me and it's easy to implement because you can test everything in the python console (even for me, I had never used python before).

But I have a question... to run my script I currently open the python console, import the module and then I run my function... The sample shows how to register funtions to use inside the spreadsheet, but:

How do can I register a menu entry to run a python function in my script?

Thanks very much!

I've read that the python plugin interface might not be stable and it's not encouraged to use it to long-term things. In my case this is not a problem because I need it for data manipulation once... I won't need it in the function... but is this still true? Is it going to change? Will perl substitute python or will both be mantained?

TIA,

Josep








[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]