Re: Excel automation on linux

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

 



On Monday 21 Feb 2005 16:32, david_coyle@xxxxxxxxxxx wrote:
> Hi all,
> I'm pretty new to the linux (Fedora Core 2) environment and hope that this
> question is suitable for this mailing list.
> I currently have a program written in C++ which is used to automate
> Microsoft Excel by writing out data to the spreadsheet and then updating
> about 10 charts based on this data in the spreadsheet. I'm not sure if any
> of you are familiar with the Microsoft environment but the program is
> developed in Visual Studio 6 and is based on the Microsoft Foundation
> Classes. I have Open Office installed on my linux machine and I know it is
> possible to open / read / write an Excel file using Open Office Calc and to
> create charts manually.
> What I'm wondering is if it is possible to automate the process of writing
> to and updating the charts in an Excel file in C / C++ code so that it will
> work in the same way as the windows program I already have and where could
> I get documentation on how to do this. If its not possible to do this with
> Excel files (although I would prefer to use Excel files), is it possible
> to automate the process using the standard Calc spreadsheet file format,
> .sxc and where could I get documentation on how to do this. Alternatively,
> would there be any way to port the program I already have on Windows to
> linux.
>
> Thanks,
> David
>
I'd figure from your email you are used to writing C/C++.

However, if you are willing to take a dive into Java, then the entire 
OpenOffice enviroment is programmable via Java .. so even without knowing 
what your problem is, I'm pretty sure you could reprogram your updates into 
Java and use the native OO spreadsheets.

Exporting to Excel is then a matter of calling the correct export routine from 
inside OO, assuming you still need Excel around at all.

You can download the OpenOffice SDK quite easily.  It provides you easy access 
to the OO internals.  Even quite low down routines can be accessed.  The 
documentation is not quite good enough yet, and there are very few examples 
around, but there's enough to get going with.

We used a similar system in one client's office to program their entire 
document flow, including integration into a 3rd party database.  I personally 
think the Java interface with OO is even more advanced than the available 
interfaces to Excel.  Once you understand the enviroment, its certainly safer 
to program, but then I would say that, I prefer java to C++.

-- 
Tony Dietrich
-------------
What use is magic if it can't save a unicorn?
  -- Peter S. Beagle, "The Last Unicorn"


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux