Re: libgsf question



If you want to create all singing, all dancing Excel spreadsheets, and you are prepared to install gnumeric, I found that writing the .gnumeric file format (it is XML) very easy, and you can then run that through ssconvert to produce a genuine Excel spreadsheet. This gives you access to most of the spreadsheet features.

In my experience, Spreadsheet::WriteExcel sometimes produces Excel spreadsheets that don't open in Excel quite right. I think this was something to do with the fact that I was producing big spreadsheets.

David

Jon K Hellan wrote:
libgsf is not sufficient for writing Excel files. libgsf handles the ole
container format, but does not help you to generate the Excel (BIFF)
records.

I'm not sure what your requirements are. If there aren't formulas in
your data, and you don't care about formatting, you could get away with
simply writing comma separated (CSV) files, and naming them "foo.xls".
This will fool Excel. If there are formulas and/or formatting, you could
try the Perl module Spreadsheet::WriteExcel, or the Java POI library.

You can also convert a CSV file to a "real" Excel file using the
ssconvert program, which comes with gnumeric. If you get want full
flexibility, and the Perl and Java modules aren't sufficient, you could
even try to write your own program using the Gnumeric machinery.

Hope this helps

Jon Kåre

On Mon, 2005-06-20 at 14:27 -0600, Kem Mason wrote:

I'm not certain this is the right forum, but I looked through the mail.gnome.org archives for this mailing list and it looks close.

The problem I'm having is this:

I downloaded libgsf in order to write (fairly simple) Excel spreadsheet files on linux.

I'm having a hard time understanding the documentation at:
http://www.gnome.org/projects/libgsf/

What I'm wondering is this:

Are there any really simple examples of how to write an excel spreadsheet? If I had a basic outline for creating one that had data in a cell or two, I don't think I'd have any problem moving forward from there. Obviously looking at the source for gnumeric, or something else that uses libgsf is a possibility (and maybe the route I need to take) -- I'm just hoping there might be some reference I'm missing that would save me a bunch of time -- not really excited about diving into code that's not intended to be an example, although if this route doesn't pan out, that's what I'll do I think.

Any suggestions / pointers welcome.

Thanks,
Kem

_______________________________________________
gnumeric-list mailing list
gnumeric-list gnome org
http://mail.gnome.org/mailman/listinfo/gnumeric-list




_______________________________________________
gnumeric-list mailing list
gnumeric-list gnome org
http://mail.gnome.org/mailman/listinfo/gnumeric-list

This message has been checked for viruses but the contents of an attachment
may still contain software viruses, which could damage your computer system:
you are advised to perform your own checks. Email communications with the
University of Nottingham may be monitored as permitted by UK legislation.




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