What is the best Ruby library for dealing with Excel spreadsheets?
I found spreadsheet-gem but I didn't find it to be as good as PHPExcel - a library I used to use when I was a PHP developer.
Please help.
Thanks.
What is the best Ruby library for dealing with Excel spreadsheets?
I found spreadsheet-gem but I didn't find it to be as good as PHPExcel - a library I used to use when I was a PHP developer.
Please help.
Thanks.
I think roo is the best gem you can get at this time. It's not almighty but might be helpful.
win32ole
There are some quirks, but I've been able to do anything I've wanted with excel spreadsheets.
excel = WIN32OLE.new('Excel.Application')
excel.visible = true
workbook = excel.workbooks.open('myspreadsheet.xls')
worksheet = workbook.worksheets("Sheet1")
worksheet.Activate
somevalue = worksheet.Cells(row, column).Value
worksheet.Cells(row, column).Value = some_other_value
I've yet to find great documentation but a good rule of thumb is between .methods.sort and doing something as an excel macro recording first you can figure a lot of stuff out.
Good luck.