Yes, that would work for your requirement Filip but I can easilly imagine another using say that the String value "$2,500" should be converted to a number and a format should be generated and applied automatically to the cell so that they did not lose the dollar sign and comma separator - and is this really the function of a setCellYtpe() method? I think that we could convincingly argue that if you try to convert a cell whose type is text or string into a numeric cell (for example) then a warning should be issued that information may be lost. In my opinion, it will not be possible to catch and handle every little requirement, so the conversion of the value should be performed and the user ought to be warned that changes may occur to the appearence of the cell.
Yours Mark B Filip Defoort wrote: > >> In my opinion, I think that poi should be changed to option (C) - >> always attempt conversion, with strict parsing. >> > > I would agree with that - it'd be really handy to have string to > number conversion, but it can be a really simple numeric parsing > without dealing with $, % and the likes. > > Cheers, > - Filip > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > > -- View this message in context: http://old.nabble.com/bug-in-cell.setCellType%28Cell.CELL_TYPE_NUMERIC%29-%28POI-3.6%29-tp27034280p27056259.html Sent from the POI - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
