+ Reply to Thread
Results 1 to 4 of 4

Conditional Formatting of a Chart

  1. #1
    Forum Contributor
    Join Date
    02-26-2012
    Location
    Ottawa, ON
    MS-Off Ver
    Excel 2007
    Posts
    129

    Conditional Formatting of a Chart

    Hi All,

    I have a list of device numbers and beside the device number I have a value (let's say this value is a turn on voltage). In my original code, I used this value column with the rank and percentile option in data analysis. Then I created a scatter plot which has the turn on voltage on the x-axis and the percentile on the y-axis.

    BUT now I have added a third column, which simply has a "Yes" or "No" representing if the device passed or not. What I would like to update on the plot is the colour. I still want the same values on the x and y axis, but now I would like each point on the scatter plot to be green or red depending on whether the device passed or not. The device doesn't necessarily fail because of the turn on voltage limits. There are other limits and parameters that determine this. For example, even if the turn on voltage was between its limits, it could have failed for another reason.

    I included the code that I have now. It is working without the colour update. Do I need to use an array instead of a range? I am not sure how to go about this.

    Thanks!

    Please Login or Register  to view this content.
    Last edited by NatalieEC; 02-08-2015 at 09:51 PM.

  2. #2
    Forum Contributor
    Join Date
    02-26-2012
    Location
    Ottawa, ON
    MS-Off Ver
    Excel 2007
    Posts
    129

    Re: Conditional Formatting of a Chart

    Okay, now I have an update. I've learned about using Points(i). In the first point of the series which is in the rank and percentile table, I search for the value in the original data set to find the row number. Then I check in the third column to see if the device passed or not. Once I check that, I use .MarkerForegroundColor to change the colour of the point. However, whether it passes or not, all the points in the scatter plot are turned black.

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    01-03-2013
    Location
    Aberdeen, Scotland
    MS-Off Ver
    Excel 2007
    Posts
    163

    Re: Conditional Formatting of a Chart

    Maybe try something like this (I assumed that every point has yes or no value):

    Please Login or Register  to view this content.
    Not very smart, but who knows...

  4. #4
    Forum Contributor
    Join Date
    02-26-2012
    Location
    Ottawa, ON
    MS-Off Ver
    Excel 2007
    Posts
    129

    Re: Conditional Formatting of a Chart

    Got it working!

    I used these lines.

    Please Login or Register  to view this content.

+ 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. conditional chart formatting
    By moldoverb in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-26-2013, 08:08 PM
  2. [SOLVED] Conditional formatting a bar chart
    By Redder Lurtz in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 02-26-2013, 07:54 AM
  3. Chart 'Conditional' Formatting
    By vtxvtx in forum Excel General
    Replies: 1
    Last Post: 12-07-2012, 12:02 AM
  4. Chart conditional formatting
    By mmckenna in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 06-25-2011, 06:01 AM
  5. Conditional Chart Formatting
    By Immortal Lobster in forum Excel General
    Replies: 2
    Last Post: 04-02-2009, 07:10 PM

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