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'm using Vodafone Mail - to get your free mobile email account go to http://www.vodafone.ie Use of Vodafone Mail is subject to Terms and Conditions http://www.vodafone.ie/terms/website
On 02/21/2005 08:32:10 AM, david_coyle@vodafone.ie wrote:
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'm not speaking from experience, but I believe you can do this with gnumeric - I'm guessing you would need to have the gnumeric devel package installed to build your product. You probably could export to excel straight from it, even if you had to do it internally in Gnumeric's spreadsheet format.
You might want to look at the gnumeric header files. There also is an interface - I think called GnomeDB - that I believe allows gnome applications (such as gnumeric) to interact with a database. Again though, I have not used it and don't really know what I'm talking about.
On Monday 21 Feb 2005 16:32, david_coyle@vodafone.ie 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++.