Within the cocoon sources under src/java/org/apache/cocoon/components/elementprocessor/impl/poi/hssf/elements/Cell.java, where it says:
} else if (_cell.getCellType() == HSSFCell.CELL_TYPE_STRING) { _cell.setCellValue(content); } else if (_cell.getCellType() == HSSFCell.CELL_TYPE_FORMULA) { you need to add: _cell.setEncoding(HSSFCell.ENCODING_UTF_16); If you want this to be a committable patch, then check for the local flag. If its not us, uk or whatever the abbreviation for austrailia is, set it to UTF 16, otherwise set it to: |ENCODING_COMPRESSED_UNICODE| <http://jakarta.apache.org/poi/javadocs/org/apache/poi/hssf/usermodel/HSSFCell.html#ENCODING_COMPRESSED_UNICODE> For further explanation see: http://jakarta.apache.org/poi/javadocs/org/apache/poi/hssf/usermodel/HSSFCell.html#setCellValue(java.lang.String) If you don't do it, I'll get around to it very soon. -Andy Hiloliddin Karimov wrote: >Hi Andrew, > ><map:serializer name="xls" >src="org.apache.cocoon.serialization.HSSFSerializer" >mime-type="application/vnd.ms-excel" locale="ru"/> > >I want made some changes to HSSF for encoding. >I don't understand what I should set and where I can get encoding mode or >type? >Suppose I get encoding mode from Configuration but where source for >encoding? >void setEncoding( ???? ) { > ???? >} >pls explain bit more. >Thanks a lot, >Hill > > >-----Original Message----- >From: Andrew C. Oliver [mailto:[EMAIL PROTECTED]] >Sent: Saturday, August 17, 2002 6:42 PM >To: Hiloliddin Karimov >Subject: Re: [Fwd: Encoding in HSSF (XLS) Serializer] > >Hiloliddin Karimov wrote: > > > >>Hi Andrew, >> >> >> >>So how I can solve my problem. >> >>Is possible show cyrillic characters in Excel by use HSSF (XLS) >>Serializer? >> >> >> >>Thanks a lot, >> >>Hill >> >> >> >If you make some minor changes to the HSSF Serializer, yes. Otherwise >you'll have to wait for me to do it. >Not that you should care, but using them makes the sheet incompatible >with gnumeric. > >All that needs to be done is if the "locale" flag is not >us/uk/austrailia then do the "setEncoding" flag in the underlying HSSF API. >Please, file a bug against Cocoon it doesn't fall through the cracks. > >-Andy > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]