+ Reply to Thread
Results 1 to 2 of 2

VBA Help - =MOD(ROW()

  1. #1
    Registered User
    Join Date
    06-27-2013
    Location
    Darwin, Australia
    MS-Off Ver
    Excel 2011
    Posts
    27

    VBA Help - =MOD(ROW()

    Hi all,

    I was given the following conditional formatting formula to help me shade 3 rows, leave 3, shade 3 etc (starting at row 2):

    =MOD(CEILING(ROW()-1,3),2)

    This works exactly how I want it to, but I'm using it on Excel 2003 and there are cells which already have 3 conditional formats so I can't add this conditional format.

    Is there a way to do the same thing but using VBA instead so I can keep my other 3 conditional formats?

    Cheers,

    Dougie

  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: VBA Help - =MOD(ROW()

    Hi, Dougie,

    maybe like this:
    Please Login or Register  to view this content.
    where you maybe would need to adjust the number of columns to fill as well as the column which hold s the constant data.

    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

+ 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