voram has asked for the wisdom of the Perl Monks concerning the following question:
Hello Monks,
I have just started using Spreadsheet::WriteExcel.
I am facing a problem where the text 801495E40 is automatically converted by excel into 8.01495E+45.
I tried to define a format for the cell and assigned it to the entire column like this:
my $textFormat = $workbook->add_format( num_format => 'Text' ); $detail->set_column('A:D', undef, $textFormat);
However, formatting the cell as above, formats it to FormatCell >> Number >> Custom >> Text type, not to the FormatCell >> Number >> Text type (which I feel would solve the problem).
Do let me know if there is any way that I can stop Excel from formatting tokens like 801495E40 (in regex terms [0123456789]+E[0123456789]+ ) to the scientific type like 8.01495E+45 considering E as an exponential factor
Thanks !
Megh
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: WriteExcel : The text 801495E40 turns into 8.01495E+45
by runrig (Abbot) on Jan 16, 2014 at 23:23 UTC | |
by voram (Initiate) on Jan 17, 2014 at 16:16 UTC | |
|
Re: WriteExcel : The text 801495E40 turns into 8.01495E+45
by ww (Archbishop) on Jan 16, 2014 at 23:44 UTC | |
by voram (Initiate) on Jan 17, 2014 at 16:24 UTC | |
|
Re: WriteExcel : The text 801495E40 turns into 8.01495E+45
by Kenosis (Priest) on Jan 17, 2014 at 00:42 UTC | |
|
Re: WriteExcel : The text 801495E40 turns into 8.01495E+45
by Laurent_R (Canon) on Jan 16, 2014 at 23:25 UTC |