Thread
:
Macro To Shade Every Other Row
View Single Post
#
5
Posted to microsoft.public.excel.programming
Don Guillett[_4_]
external usenet poster
Posts: 2,337
Macro To Shade Every Other Row
You answered what I said with what I said?
--
Don Guillett
SalesAid Software
"Dsuperc" wrote in message
om...
One way to make your data legible is to apply cell shading to every
other row in a range. Excel's Conditional Formatting feature
(available in Excel or later) makes this a simple task.
Select the range that you want to format
Choose Format, Conditional Formatting
In the Conditional Formatting dialog box, select Formula Is from the
drop-down list, and enter this formula:
=MOD(ROW(),2)=0.
Click the Format button, select the Patterns tab, and specify a color
for the shaded rows.
Click OK twice to return to your worksheet.
The best part is that the row shading is dynamic. You'll find that the
row shading persists even if you insert or delete rows within the
original range.
"Don Guillett" wrote in message
...
Without a macro, use conditional
formattingcondition1=mod(row(),2)=0format patterns graycopy the
format.
easier when you add and delete
--
Don Guillett
SalesAid Software
"Jason" wrote in message
...
I have the following Range: "A10:Z2000". I am trying to figure out
some
code that would allow me to begin with row 10 within the range, and
highlight
every other row with a light shade of grey until it reaches the end of
the
range. Some of the cells will have other formats in place (Number,
Percentage, etc), so I would want the shading to occur with the
existing
formats remaining in place. Can anyone help. Thanks.
Jason
Reply With Quote
Don Guillett[_4_]
View Public Profile
Find all posts by Don Guillett[_4_]