• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Highlight columns 2 at a time, alternating

leimst

Member
Hello,

I have a spreadsheet where the data is associated in pairs...so 2 columns at a time. For example:

A B C D E F

Old Date New Date Old Time Stamp New Time Stamp Old Cost New Cost


Is there a way to highlight 2 columns at a time such that the Date columns would be light gray but the Time Stamp columns would have no color and then the Cost columns would be light gray and continuing that pattern until the last column?


I suspect that a macro would be the only solution?


Thank you in advance for any help,


Leimst
 
Good day leimst


Just highlight two columns together AB by clicking in the cells with the column letters in click in one A and drag to the other cell B and then from the fill icon choose your colour then do again CD you may have to reselect your column groups AB CD EF GH and apply all borders.You may have to re-colour your first cells with the headers in
 
Hi Leimst,


Select all the cells.. (A to F),

Apply Conditional Formatting.

Use Formula..
Code:
=MOD(COLUMN(),2)=0

and select your desired color..


Regards,

Deb
 
I think this is what you are looking for:

https://www.dropbox.com/s/01neaoj9e0nb6j4/Color%202%20Columns%20at%20a%20time.xlsx


Uses conditional formatting to color two columns at at time.
 
Or, if you're already using a Table/List in XL 2007+, you can just modify the formatting settings.

http://chandoo.org/wp/2012/09/19/custom-zebra-lines-table-styles/


I'm personally falling in love more every day with Tables since they dynamically grow and allow easier cell referencing.
 
@Nick M - that worked perfectly, thank you!


@Luke M - I wasn't aware of that feature. I tried it however I have not been able to get it to work in applying the highlighting to columns. I must be doing something wrong.
 
Back
Top