parsing - Spreadsheet.open in Rails gives this error "unknown encoding name - MACINTOSH" -


i using spreadsheet parse xls files. it's working great. today 1 of user has uploaded file , it's getting error "unknown encoding name - macintosh"

my code is: book = spreadsheet.open file_path sheet1 = book.worksheet 0

this excel file getting error: https://www.dropbox.com/s/jv37pk5rpiy9259/testlisttextnonames2.xls

can guys please me solve issue.

running same problem. here best can deduce:

"macintosh" not known encoding in ruby 1.9+. try opening console , running "encoding.find('macintosh')". you'll same error.

so available? in console: "encoding.list". 1 of options macroman. i'm guessing close second.

so if change mapping in lib/spreadsheet/excel/internals.rb 10000 , 32768 map "macroman", should work.

tested locally , does.

i opened pull request: https://github.com/zdavatz/spreadsheet/pull/51

some reference links: * https://en.wikipedia.org/wiki/mac_os_roman * http://bugs.python.org/issue843590


Comments

Popular posts from this blog

Delphi XE2 Indy10 udp client-server interchange using SendBuffer-ReceiveBuffer -

Qt ActiveX WMI QAxBase::dynamicCallHelper: ItemIndex(int): No such property in -

Enable autocomplete or intellisense in Atom editor for PHP -