Sep 28, 2012 at 1:13 PM
Edited Sep 28, 2012 at 2:26 PM
I'm using PhpExcel 1.7.7. When I try to set cell value using this code
/* insert this code into Tests/30template.php, after line #40 */
$objRichText = new PHPExcel_RichText();
$objRichText->createText('nakład'); # polish word in UTF8
and save output as Excel5 then it's unreadable by Excel and OpenOffice shows random characters in row #20 (yes, value was set to A11).
Changing PHPExcel_Shared_String code from using iconv to mbstring didn't help.
When I set cell value without RichText, as below, then everything works fine.
$objPHPExcel->getActiveSheet()->setCellValue('C1', 'nakład'); # OK
PS When trying to save it as Excel2007, encoding works correct, but text formatting is wrong (text 'You have 2 errors: [red]some error[/red], [red]another error[/red]' becomes 'You have 2 errors: [red]some error, another error[/red]') so it's useless for
PS2 In 1.7.6 createText works OK (despite createTextRun doesn't)