Is it possible to save conditional formatting rules for reuse in a new workbook?

9

3

I want to make some rules that I can haves saved that I can easily apply to new workbooks as needed. It's a pain doing it how I currently do where I'm always having to go back through and recreate these conditional format rules. If this is unclear please let me know and I'll try explaining better.

My apologies... so here is a better description of the issue.

I have values that I want to color code that come up all the time in documents I create. For instance, I might have a sample document like the following:

Jane       2.1
Steve      4.5
Caleb      4.4

I want to have the cells with the numbers formatted a certain way based on the numbers falling within a certain range. So each time this comes up in a document I end up created 7+ conditional rules for the 7 or more number ranges. These rules never change except for every 3 years or so. It would be nice to be able to have them save and then I can just use format painter or something to apply them to certain columns when creating a new document.

Hope this helps explain the situation!

fwaokda

Posted 2013-04-11T13:20:13.413

Reputation: 289

Can I save conditional formatting rules for use in other workbooks? [Excel 2010] http://answers.microsoft.com/en-us/office/forum/office_2010-excel/can-i-save-conditional-formatting-rules-for-use-in/347098e6-b027-48d8-998e-3f0532958d74?msgId=e3c95715-e1a8-4f18-a2fc-47a801b60b46 Easily found by Googling 'excel save conditional formatting'

– Jan Doggen – 2013-04-11T14:03:44.423

You could store your rules in VBA macro. If you have no experience with VBA try to start recording before you will set CF rules next time. Don't be surprised- if you have complicated CFs that you could result with complicated (but understandable) code. If it is something easy try @JanDoggen link with a bit help of recorder. – Kazimierz Jawor – 2013-04-11T14:06:44.563

Answers

4

You can use a template to save the all of the conditional formatting rules.

  1. Start with a blank spreadsheet.
  2. Add any content you want to appear in new spreadsheet.
  3. Add the conditional formatting rules you want in each new spreadsheet.
  4. Use Save As and choose Excel Template
  5. When creating a new spreadsheet choose My templates and then the template you want.

template

Brad Patton

Posted 2013-04-11T13:20:13.413

Reputation: 9 939

But how do you save and reuse the conditional formatting rules? – endolith – 2013-09-11T20:04:41.723

@endolith: Based on your requirements (which, AFAIK, cannot be satisfied), Brad’s answer is even worse than mine.  In step 4, he saves a copy of the workbook, complete with all formatting, as a template file.  And in step 5 he creates a new workbook that is a copy (duplicate / clone) of the original workbook, complete with all formatting. – Scott – 2013-09-11T22:46:08.660

@Scott: Yeah I created a macro and made a button for it, which seems to be working well – endolith – 2013-09-12T14:22:01.247

4

It looks like you’ve got the answer right there in your question –– or am I missing something?  You can use “Format Painter” (in the “Clipboard” panel of the “Home” tab).

  1. Create a file that has your chosen formats.  Save it.    ...    Later,
  2. Create or open a new file with data.
  3. Reopen your original file.
  4. Click on a cell that has the format(s) that you want to use.
  5. Click on “Format Painter”.
  6. Switch over to the new file and click on the cell(s) to which you want to apply the format(s).

Following standard “Format Painter” semantics, if you want to copy a format (or a format collection) to multiple ranges, double-click on “Format Painter”.

Scott

Posted 2013-04-11T13:20:13.413

Reputation: 17 653

I think the OP was about using conditional formatting which I don't think Format Painter copies. – Brad Patton – 2013-04-12T00:23:01.860

@Brad: It does in Excel 2007. – Scott – 2013-04-12T00:25:39.920

ahh it does in 2010 as well. But it appears to change the data range. If I have a rule for the entire worksheet and 'paint' it to another worksheet the range changes to the cells I paint which may or may not be fine for this case. – Brad Patton – 2013-04-12T00:33:41.287

Well, that is what I said: “6. Switch over to the new file and click on the cell(s) to which you want to apply the format(s).” – Scott – 2013-04-12T00:36:20.890

This copies all formatting, though, and/or deletes existing formatting. It doesn't just copy the conditional formatting rules. I want a way to save a set of rules with a name and then apply that rule to a selection, the way you can drop down and choose a color scale, for instance. – endolith – 2013-09-11T20:17:44.203

3

record a macro,run it the next time you have to apply the conditional format.

truthurt

Posted 2013-04-11T13:20:13.413

Reputation: 69

I recorded a macro of applying 2 conditional formattings to a range, saved to Personal Macro Workbook, then followed these directions for making a quick button. Now I can select a range and click the button and the conditional formatting is applied. It only applies to the selected range (color-highlight extreme values), so it works correctly.

– endolith – 2013-09-12T14:51:20.587