How to retain background colors when pasting between documents in Excel
Posted
by Iain Fraser
on Super User
See other posts from Super User
or by Iain Fraser
Published on 2010-02-12T00:19:37Z
Indexed on
2010/04/30
10:07 UTC
Read the original article
Hit count: 391
I have a script that programatically generates excel spreadsheets - cleaning up ugly reports that are given to us from another organisation. For interests sake; I'm using PHPExcel to generate the "clean" reports.
We get these reports every week for an event that happens every couple of months. The reports contain a list of attendees along with a group id that allows us to know that some attendees belong together.
To help the event organisers out, I've taken the event ID and generated a unqiue color code (based on the hash of the event ID - truncated to 6 characters). This unique colour code is set as the background color of a cell in each row. This helps organisers quickly visually identify group members.
Trouble is, when the organisers copy the rows from the weeks report into the master report (which contains all attendees, not just the ones that signed up this week) - all the colour-codes snap to the master template's color pallette.
Thank you very much for your time
All the best Iain
© Super User or respective owner