How to create a chart that ignores blank cells?
How to create a chart that ignores blank cells?
I typically use formula to return #N/A which will be ignored in chart.
You can use =NA()
Other than that, can you upload sample file?
?Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something.?
― Robert A. Heinlein
This is the most comprehensive essay on how charts treat blank (including those that look blank but are not really blank) cells that I am aware of: https://peltiertech.com/mind-the-gap...g-empty-cells/
Originally Posted by shg
I'm assuming a few things here.
1) you have chart data that varies - otherwise you simply do not cover the range with the blanks.
2) it might be complex and you are willing to go with complex (VBA) solutions.
The way I do it is I set up a formula that shows whether or not the chart data area is greater than zero. This is a simple =C21>0 if it is then TRUE, if not then FALSE.
Next, I set up a table name for the range and I name it TrueFalseRange (subsequent ones I add a number to the end).
Then I set up a macro.
Where "calculations" is the tab name where the data and the true false ranges are that are in the graphs.HTML Code:
Then I have dropdowns in the graphs where the person can select different locations and for the macros to work on the graphs and right click and pick assign macro and assign to the MacroHideUnhide so the macro functions for the graph. Finally you have to save it as a macro enabled workbook.
This macro will hide the rows where the data is 0 and it will disappear from the graphs.
<><><><><>
if this isn't what you are looking for you'll have to be more specific with your question.
Make contributors happy, click on the "* Add Reputation" as a way to say thank you.
Sam Capricci
Of course it took a while for me to type the reply and while doing you've had two very good responses. I like CK76s reply and may give that a try in the future and will have to look at MrShorty's reply.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks