Bug 121689 - Copy&Paste cells with condition to external programs (Word/Moodle) doesnt work properly
Summary: Copy&Paste cells with condition to external programs (Word/Moodle) doesnt wor...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
(earliest affected) release
Hardware: All All
: medium normal
Assignee: Not Assigned
Depends on:
Blocks: Paste
  Show dependency treegraph
Reported: 2018-11-24 11:28 UTC by Eduardo
Modified: 2018-12-28 08:24 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:

copy & paste from calc to word (21.59 KB, image/png)
2018-11-24 15:25 UTC, Oliver Brinzing
a simple conditional format example (8.39 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-11-24 15:25 UTC, Oliver Brinzing
copy from lo to word and calc (235.52 KB, image/jpeg)
2018-12-02 12:58 UTC, Oliver Brinzing
copy from lo to word and calc with changed values (231.74 KB, image/jpeg)
2018-12-02 12:58 UTC, Oliver Brinzing
extract from NotesM4XML1819B.ods (14.38 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-12-04 18:42 UTC, Oliver Brinzing

Note You need to log in before you can comment on or make changes to this bug.
Description Eduardo 2018-11-24 11:28:58 UTC
I have some cells in libreCalc. In fact a table with names of pupils and their marks. In the mark sell i have a condition ( paint background red if mark is less than zero and greater than 10, just to avoid typing errors).
When i copy this table to moodle or word, it appears the cells with background red, although the cell value is correct. In librecalc appears with background white.

If i delete the conditionals, it works as expected

Steps to Reproduce:
1.Make a Cell with conditional format ( ex: background red with marks less than 6)
2.Put in the cell a correct value ( ex: 7). It shows ok in calc.
3.Copy the cells and paste it in Moodle or Microsoft Word.... It apperas the cells with background red, although the value is correct.

Actual Results:
Paste with wrong conditions format

Expected Results:
Paste as its shown in calc. The same format and values.

Reproducible: Always

User Profile Reset: No

Additional Info:
Comment 1 Oliver Brinzing 2018-11-24 15:24:35 UTC
I can't reproduce it in

Version: (x64)
Build ID: 86daf60bf00efa86ad547e59e09d6bb77c699acb
CPU threads: 4; OS: Windows 10.0; UI render: default; 
Locale: de-DE (de_DE); Calc: 

To be certain the reported issue is not
related to corruption in the user profile, could you please reset your
Libreoffice profile ( https://wiki.documentfoundation.org/UserProfile ) and

Please attach a sample document, as this makes it easier for us to verify the bug. 
(Please note that the attachment will be public, remove any sensitive information before attaching it. 
See https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F for help on how to do so.)

I have set the bug's status to 'NEEDINFO'. Please change it back to
'UNCONFIRMED' if the issue is still present
Comment 2 Oliver Brinzing 2018-11-24 15:25:10 UTC
Created attachment 147000 [details]
copy & paste from calc to word
Comment 3 Oliver Brinzing 2018-11-24 15:25:45 UTC
Created attachment 147001 [details]
a simple conditional format example
Comment 4 Eduardo 2018-11-24 18:59:13 UTC
Seems if i copy to writer dont happen...
But in moodle and word happens...
I have reseted profile.
Your example seems to work

The difference perhaps is that i use two conditions: value greater than zero and value less than D14 ( for example)
Comment 5 Eduardo 2018-11-24 19:08:04 UTC

I have added a example which im currently working...the first column is the name of pupil the second the maximum of that question, i put a different color if the mark is less than zero or more than the maximum mark fot that question...As all the numbers are correct, calc shows it ok, writer also, but importing to excel, word and moodle ( at least) the appear the orange background ( the color assigned to cells that are failing the conditions.

I can also send a mail or upload to that folder in google drive if you want to take a look.

Comment 6 Eduardo 2018-11-24 19:20:57 UTC
Also making some tests, i noticed than in writer the paste default option is to paste as libreoffice calc object, but in word, excel and moodle is html.. So i guess the problem is special paste in html.
Comment 8 Oliver Brinzing 2018-12-01 17:03:34 UTC
(In reply to Eduardo from comment #7)

i cannot find an example file, only jpg's.
could you please attach a simple example file, where the bug can be reproduced?
Comment 9 Eduardo 2018-12-02 12:12:02 UTC
Added calc example i thought that with jpg and my comments were enough...
You can go for example to sheet Practica1...there are thre questions, with a maximum mark for each...there are now all correct, copy and paste whatever part of the marks and students an in jpg is shown...paste it in  moodle, word, excel or in writer in html mode...you would see it shows as if the condition was not successs.....any more information tell me...there also some other bugs that i filled that you can also test....thanks for your help....
Comment 10 Oliver Brinzing 2018-12-02 12:58:29 UTC
Created attachment 147220 [details]
copy from lo to word and calc
Comment 11 Oliver Brinzing 2018-12-02 12:58:59 UTC
Created attachment 147221 [details]
copy from lo to word and calc with changed values
Comment 12 Oliver Brinzing 2018-12-02 13:02:20 UTC
added to screenshots showing copy & paste from lo to word/excel.
Comment 13 Eduardo 2018-12-02 18:43:52 UTC
Comment on attachment 147220 [details]
copy from lo to word and calc

Incredible...now it also works for me.....
Just try another one M4* the sheet Pr1

Sorry for inconvenience
( i was not dreaming you can see the screenshots...)
Comment 14 Oliver Brinzing 2018-12-03 17:55:15 UTC
(In reply to Eduardo from comment #13)
> Sorry for inconvenience
> ( i was not dreaming you can see the screenshots...)

setting to resolved/worksforme :-)
Comment 15 Eduardo 2018-12-04 09:31:01 UTC
Please try with this spreadsheet ive uploaded: called M4* the sheet Pr1...
Comment 16 Oliver Brinzing 2018-12-04 18:40:41 UTC
confirming problem with extract from NotesM4XML1819B.ods
Comment 17 Oliver Brinzing 2018-12-04 18:42:29 UTC
Created attachment 147289 [details]
extract from NotesM4XML1819B.ods

steps to reproduce:
- open attachment
- select B14:F18
- copy & paste into word
- cell background changes
Comment 18 Xisco Faulí 2018-12-05 16:34:36 UTC
question is: is it a LibreOffice problem or a MS Office problem ?
Comment 19 Xisco Faulí 2018-12-05 16:39:08 UTC
Does it happen if it's pasted to another office suite? WPS, onlyoffice ?
Comment 20 Eduardo 2018-12-06 12:11:49 UTC
Before i have added a google drive folder with two examples...

I think is libreoffice, because both on moodle and microsoft word the paste is not correct. Also if you paste in writer with html paste mode doesnt work...

As i guess is something related to html, you dont paste the same you copy...