+ Reply to Thread
Results 1 to 2 of 2

Code for Highlighting cells linked to formula

  1. #1
    Registered User
    Join Date
    06-13-2023
    Location
    Oman
    MS-Off Ver
    Office 365
    Posts
    3

    Code for Highlighting cells linked to formula

    Hi,

    if I need to highlight all cells linked to a formula cell

    Example Revenue Cell result from adding different cells in the workbook, I need to highlight those cells

  2. #2
    Forum Contributor
    Join Date
    10-30-2014
    Location
    England
    MS-Off Ver
    2007 / 365
    Posts
    279

    Re: Code for Highlighting cells linked to formula

    If the cells are on the same worksheet you can just select your formula cell then Find & Select > Go To Special... > Precedents . Then you can just select your fill color.

    If there are cells on other worksheets you may need to split the cell references within the formula to an array, then loop over them, checking if each one is a valid cell reference, before applying a cell color.

    Unfortunately I'm not in a position to be able to write any code for this at the moment.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. VBA Code for Highlighting Cells based on If then Rules
    By SKD7 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-20-2022, 02:21 AM
  2. Replies: 3
    Last Post: 06-09-2022, 01:12 PM
  3. VBA code shortening - HIGHLIGHTING CELLS
    By RysiuTaxiDriver in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-07-2021, 10:28 AM
  4. [SOLVED] Need to validate contents of cells linked cells, highlighting those that require fixing
    By Hirad001 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-23-2015, 09:37 AM
  5. [SOLVED] VBA Code for highlighting cells if it appears elsewhere
    By mpgates in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 12-11-2013, 02:28 AM
  6. Replies: 6
    Last Post: 08-28-2005, 05:05 PM
  7. [SOLVED] Highlighting linked columns
    By Cheri in forum Excel General
    Replies: 3
    Last Post: 01-13-2005, 12:06 AM

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