| View previous topic :: View next topic |
| Author |
Message |
rparker General User

Joined: 15 May 2011 Posts: 6
|
Posted: Sun May 15, 2011 10:08 am Post subject: OO.Calc Import question |
|
|
In the past, I've used a DDE server to import live data into an OO.Calc spreadsheet. But now, I'm using static CSV files as the data sources and want to update individual cells in the spreadsheet automatically throughout the day on a server... unattended. I have all the CSV files updating from data getting scraped off of various websites at specific times. I'm also ready to write unique batch files to launch the spreadsheet and run a specific Macro at that time to update the value from the CSV in question using the following format in the batch files:
"C:\Program Files\OpenOffice.org 2.3\program\soffice.exe" "macro:///OOForum.Base.openForm2(Form11)"
Then, I just want to save and close the application at the end of the macro.
However, I've searched this forum (and it feels like I've gone to the moon and back, really) and I still haven't found a macro to do something like this: put the single value from a local CSV file into a specific cell in the spreadsheet. Then, it should save and close the spreadsheet until the next batch file runs for the next CSV. Again, there is only one row of information in each CSV. I just need to direct OO.Calc to import it to a specific cell.
I have some experience using MSSQL and have already looked at OO.Base because someone recommended that in another post for something like this. But I don't have enough data for this to be practical. I'm looking at 14 records total. So it seems like this should be done in OO.Calc directly. I just need to update this spreadsheet unattended 14 times a day.
Thanks for any help you can provide,
R |
|
| Back to top |
|
 |
rparker General User

Joined: 15 May 2011 Posts: 6
|
Posted: Sun May 15, 2011 11:51 am Post subject: Update |
|
|
I came across this thread and was wondering if PERL is how I should be approaching this rather than macros:
http://www.oooforum.org/forum/viewtopic.phtml?t=93417
I don't know Perl at all so if someone can help me understand what's required to complete my project, it'd be a big help.
My understanding right now is that PERL can parse CSV files. But how do I tell PERL where to input the data from the CSV to the spreadsheet? And then.. how do I save and close the spreadsheet?
I guess I'm going to start researching PERL but if anyone can point me in any direction, I'd appreciate it.
Thank you,
R |
|
| Back to top |
|
 |
rparker General User

Joined: 15 May 2011 Posts: 6
|
Posted: Sun May 15, 2011 7:05 pm Post subject: Solved |
|
|
I gave up on the macros. I'm writing scripts with AutoIt. It looks like this is exactly what I need.
Thanks,
R |
|
| Back to top |
|
 |
Villeroy Super User


Joined: 04 Oct 2004 Posts: 10065 Location: Germany
|
|
| Back to top |
|
 |
|