Issue 90218 - Saving spreadsheet loses formatting
Summary: Saving spreadsheet loses formatting
Status: CONFIRMED
Alias: None
Product: General
Classification: Code
Component: chart (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-06-01 16:34 UTC by ofish
Modified: 2017-05-20 11:28 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Spread sheet to demonstrate formatting changes (196.43 KB, application/vnd.oasis.opendocument.spreadsheet)
2008-06-01 16:36 UTC, ofish
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description ofish 2008-06-01 16:34:46 UTC
When saving spreadsheet number formatting is lost in displayed spread sheet.
Description:

1. Open attached spread sheet
2. Goto sheet "Gold"
3. Enter "xyz" into cell C112
4. Press "Save"
5. Decimal places in colums N and P are changing after save is complete.
Comment 1 ofish 2008-06-01 16:36:08 UTC
Created attachment 54133 [details]
Spread sheet to demonstrate formatting changes
Comment 2 ofish 2008-06-01 17:18:15 UTC
Same error occurs with oocalc-2.3 under Windows.

After deleting "Chart" sheet from sample spread sheet, this error no longer
shines up.
Comment 3 kla 2008-06-11 16:41:41 UTC
confirmed
Comment 4 ooo 2008-06-11 17:29:48 UTC
The culprit is the last chart "Scheidekosten Silber über Feingehalt.ist" that
seems to mess around with the number formatter. It's already sufficient to
activate the chart once with a double click and then go back to sheet "Gold" and
see the decimals changed. Effectively the user-defined number format  0.000 
that was assigned is gone from the list of available number formats then, so the
General format is applied. Same happens when forcing a hard recalc using
Shift-Ctrl-F9. Deleting the chart immediately after having loaded the document
makes the document behave well.

@iha: Ingrid, one for you, I guess ;-)
Comment 5 ooo 2008-06-11 17:31:19 UTC
Adapting component.
Comment 6 IngridvdM 2008-06-24 16:50:14 UTC
The number format of the columns N and P gets lost because in xmloff a volatile
number format is removed from the number formatter that better not have been
removed.
The numberformat N128P0 in object 13 is volatile:
<number:number-style style:name="N128P0" style:volatile="true"><number:number
number:decimal-places="3" number:min-integer-digits="1"/> and therefor is
deleted in method SvXMLNumImpData::RemoveVolatileFormats.
But a same numberformat containing 3 decimal places and min-integer-digits=1 is
already used in calc. As the chart and calc do share the numberformatter this
used numberformat is deleted wrongly.
@Niklas, do you have an idea for a fix here? As cvs annotate tells, you have
introduced the methods some years ago. Thanks, Ingrid.
Comment 7 Marcus 2017-05-20 11:28:09 UTC
Reset assigne to the default "issues@openoffice.apache.org".