+ Reply to Thread
Results 1 to 5 of 5

Is there a quick way to...

Hybrid View

  1. #1
    pezoids
    Guest

    Is there a quick way to...

    highlighting only the odd or even numbered rows?



    Thanks.



  2. #2
    Utkarsh
    Guest

    Re: Is there a quick way to...

    Something like this should do:

    Sub banding()
    ActiveSheet.Range("A65536").Select
    Selection.End(xlUp).Select
    lastrow = ActiveCell.Row
    Range("A6:AK" & lastrow).Select
    Selection.Interior.ColorIndex = xlNone

    'Change rownum to the the first row number where data occurs

    rownum = 6
    For i = 1 To (lastrow - rownum) Step 2
    Range("B" & rownum + i & ":AK" & rownum + i).Select
    With Selection.Interior
    .ColorIndex = 15
    .Pattern = xlSolid
    End With
    Next i
    End Sub


  3. #3
    Ruffed Grouse
    Guest

    Re: Is there a quick way to...

    Try highlighting the entire sheet, and using conditional formatting,
    make Canodition1 be "Formula Is" =EVEN(ROW(A1))=ROW(A1), and set the
    formatting to highlight the background.


  4. #4
    Gord Dibben
    Guest

    Re: Is there a quick way to...

    You can do this using Conditional Formatting.

    Select a range of rows.

    Format>CF>Formula is:

    For colored even rows enter =MOD(ROW()+1,2)=1

    For colored odd rows enter =MOD(ROW(),2)=1


    Gord Dibben Excel MVP

    On Wed, 28 Sep 2005 07:39:44 -0400, "pezoids" <[email protected]> wrote:

    >highlighting only the odd or even numbered rows?
    >
    >
    >
    >Thanks.
    >



  5. #5
    pezoids
    Guest

    Re: Is there a quick way to...

    Great. Thanks for the replies!



+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1