+ Reply to Thread
Results 1 to 3 of 3

Insert chart series label based on condition using for each - next loop

  1. #1
    Forum Contributor
    Join Date
    11-21-2013
    Location
    KL
    MS-Off Ver
    Excel 2010
    Posts
    168

    Thumbs down Insert chart series label based on condition using for each - next loop

    Hi all,

    I would like to add labels to a chart series based on codition.
    I have 3 columns, eg like below. If the number is negative, then do nothing. If positive then add label to the series point with the value on the respective column 3.
    eg. point 1, negative 0.5, no label. point 4, 0.2, point label 96

    1 -0.5 97
    2 -0.45 98
    3 -3 97
    4 0.2 96
    5 0.3 87
    6 0.6 98
    7 -0.4 99
    8 -0.6 98
    9 0.7 97
    10 0.8 98


    However, I received runtime error 2147467259 when running the code.

    Hope I explain clearly. Can anyone please assist?

    Thank you.

    Please Login or Register  to view this content.
    Thank you!!

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

    Re: Insert chart series label based on condition using for each - next loop

    You need to apply data labels before you can start altering what they display.

    Please Login or Register  to view this content.
    Cheers
    Andy
    www.andypope.info

  3. #3
    Forum Contributor
    Join Date
    11-21-2013
    Location
    KL
    MS-Off Ver
    Excel 2010
    Posts
    168

    Re: Insert chart series label based on condition using for each - next loop

    Hi Andy,

    Woh, thanks for pointing out. Saves me hours of time.
    Thank you!

+ 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. [SOLVED] Need to insert Day X-axis label on Chart
    By Dana_Watershed in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 09-18-2014, 11:11 AM
  2. Loop to insert data to a series of sheets
    By KeithMale in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-28-2013, 12:46 PM
  3. [SOLVED] Changing all columns in a chart to display a series name label
    By moty.98 in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 11-26-2012, 05:09 AM
  4. Replies: 1
    Last Post: 09-02-2011, 08:57 AM
  5. Pie Chart - Adding 2nd data label series?
    By Bjornago in forum Excel General
    Replies: 6
    Last Post: 01-19-2010, 08:39 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