I am reading in an Excel file with Hebrew text in it.
It seems that Excel keeps thes string in UCS-2BE encoding, whatever that would be.
I am using this code but obviously I am not too satisfied with the idea of overriding
the private classes of the module.
What else could I do with this?
sub Spreadsheet::ParseExcel::Simple::_Sheet::next_row {
my @values;
foreach my $cell (@{$_[0]->{sheet}->{Cells}[$_[0]->{row}++]}) {
if ($cell) {
if (defined $cell->{Code}) {
if ($cell->{Code} eq "ucs2") {
push @values, decode("UCS-2BE", $cell->{Val});
} else {
push @values, "";
}
} else {
push @values, $cell->{Val};
}
} else {
push @values, "";
}
return @values;
}