+ Reply to Thread
Results 1 to 7 of 7

Formatting data labels

  1. #1
    Registered User
    Join Date
    12-13-2013
    Location
    Detroit, MI
    MS-Off Ver
    Excel 2013
    Posts
    7

    Formatting data labels

    Constructed a waterfall chart with column labels "blank", "up", and "down". The down column will return a positive label (-MIN(cell reference)) and I want it to show as a negative on my chart. How do I do this? The value in the cell cannot be negative as it will just drop below the x-axis and throw off my charts. I want everything to remain the same and just throw some parenthesis around all my down values on the chart labels. Is there a VBA macro that will allow me to do this? Thanks in advance...

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,718

    Re: Formatting data labels

    Very difficult to try to imagine what you're doing from this explanation. I don't see the problem in plotting a negative value as a negative value; it would be much easier to understand with your file.

    To post a file:
    1. Under the text box where you type your reply click the Go Advanced button.
    2. In the next screen look above the reply box and click the "paper clip" icon. You will get a pop-up screen.
    3. In the pop-up, click Add then Select to select a file from your local drive
    4. Click the Upload button to upload the file
    5. Click Done to attach it.

    It will be displayed as an attachment underneath your post text. Alternatively as the last step you can click the Insert Inline button and a hyperlink to the file will be inserted directly into your post text in the spot where your cursor is set at the moment you click the button.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

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

    Re: Formatting data labels

    You can apply a different number format to the data labels than that used by the chart for the data point.
    Attached Files Attached Files
    Cheers
    Andy
    www.andypope.info

  4. #4
    Registered User
    Join Date
    12-13-2013
    Location
    Detroit, MI
    MS-Off Ver
    Excel 2013
    Posts
    7

    Re: Formatting data labels

    Thanks, I went through a crap load of Macro examples on number formatting to do this. This is much easier. But, do you have any template for an If, then Macro...to recognize any of the "down" or "negative" data points and automatically format them $(0.00)?

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

    Re: Formatting data labels

    Why? there is no need for code.
    You simply need to use the custom number format on the data labels. So the Negative series, although it contains postive values has the number format
    (General)

  6. #6
    Registered User
    Join Date
    12-13-2013
    Location
    Detroit, MI
    MS-Off Ver
    Excel 2013
    Posts
    7

    Re: Formatting data labels

    I understand how to format the numbers. These charts will be run a few times a week and those negatives may move to positive and vice versa. Hence, I would like to set it up so that anything which populates my down series will be formatted ($0.00). If I change a down value to the ($0.00) format, and the following week that number is a positive (up), it will still have that ($0.00) format, right? And if I have several charts that are, right now, all positive up values, I want to be prepared for those numbers to change to negatives as well and be formatted correctly. Am I not understanding some automated method that you have already provided? If so, Sorry, please explain when you get a chance.

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

    Re: Formatting data labels

    In my example column F contains the values for negative data points in the chart.
    If you format that series' data labels with, (General), then any time a negative datapoint is show it will include the brackets.

+ 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 Data Labels formatting using Macros
    By booo in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 03-09-2011, 04:00 PM
  2. Replies: 2
    Last Post: 02-17-2011, 02:13 AM
  3. There is a bug in formatting charts data labels.
    By leonardo.frazao in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-30-2006, 12:35 AM
  4. Formatting all data labels on a chart at once
    By VancitysFinest in forum Excel General
    Replies: 1
    Last Post: 02-09-2006, 07:50 AM
  5. Technical formatting in data labels
    By MBelchamber in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 02-15-2005, 12:06 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