+ Reply to Thread
Results 1 to 2 of 2

Change Shape Color based on Cell Value

  1. #1
    Registered User
    Join Date
    03-11-2017
    Location
    Philippines
    MS-Off Ver
    2013
    Posts
    59

    Change Shape Color based on Cell Value

    Hello,

    I have 24 shapes (might increase) and I'm hoping to change the shape color based on cell value in a column ("Red","Green","Yellow").

    hoping someone might help because linked picture is not an option and I don't know what to do anymore.

    Thanks!

  2. #2
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,419

    Re: Change Shape Color based on Cell Value

    One way is a udf.

    Add to standard code module
    Please Login or Register  to view this content.
    To use the formula on the worksheet.

    =UDFSHAPEFILL("Oval 1",VLOOKUP(F3,{"Red",255;"Yellow",65535;"Green",65280},2,FALSE))

    The values after the colour descriptions is the RGB value to be used.

    A non VBA solution, depending on the shapes is to use conditional formatting on a cell and a transparent shape with solid border to cover areas of the cell that are not to be shown.
    Last edited by Andy Pope; 07-24-2019 at 03:27 AM.
    Cheers
    Andy
    www.andypope.info

+ 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. Change the Color of Shape in Excel Based on Cell Value using VBA
    By kskhan in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-17-2019, 10:57 PM
  2. VBA change shape color based on cell value
    By noelmus in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-29-2018, 06:31 PM
  3. [SOLVED] Change the background color of a shape based on the value of a cell
    By domz3669 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 04-17-2018, 04:04 AM
  4. change shape color based on a cell value on another sheet
    By aleenkhan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-14-2017, 11:14 AM
  5. VBA: Change Shape Color based off cell value
    By emmz5d in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-26-2016, 04:35 PM
  6. [SOLVED] Change Shape Fill Color Based on Cell Value
    By Justair07 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 11-28-2013, 09:35 AM
  7. Change Shape Color based on Cell Values
    By obriend in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-22-2013, 03:26 AM

Tags for this Thread

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