jppinto:
ah, ok. thanks for info. hope it's ok if i won't accept your message as a solution... at the moment.
thanks!
regards.
Main Topics
Browse All Topicshi, guys.
i've beeng googling this around for hours but i can not seem to find an answer.
i'm trying to prepare a pie chart report and one or more cells contain "" value.
example data:
A B
1 How old are you?
2 15-20 y/o 15
3 21-25 y/o 12
4 26-30 y/o 20
5 31-40 y/o 26
6 41-45 y/o
7 46-50 y/o 3
8 51-60 y/o
if i graph the above data using pie chart with labels, the labels for 41-45 y/o and 51-60 y/o are showing 0 (zero) even if it doesn't have 0 value on their cell.
how do i remove the 0 (zero) label under these category? i can't find any option in the menu and if possible, no macros.
thanks and best regards.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Hello gharz,
Assuming that your cells contain formulas that return the count, then the pie chart will display the 0 even if the formula returns the =NA() function or an empty string ="". There are two workarounds for this without using VBA:
1) Clear the formula from the cells that have a count of 0. A truly blank cell won't show up in the pie chart.
2) Filter the data to hide the rows that contain a count of 0. You can do this manually or automatically with an AutoFilter. The manual procedure may be found on the Home menu, under Cells...Format...Hide and Unhide...Hide Rows.
Regards,
Brad
gharz,
After some further testing, I see that an exploded pie chart will display the sliver even if the count cell is completely blank. A non-exploded pie chart won't have this issue.
If you want to use an exploded pie chart, consider hiding the rows with 0 count using a filter. Neither the sliver nor the 0 value appear.
Brad
hi, brad.
thanks for the info.
my excel sheet has 5 charts and the data are taken from a SQL server. the data cells has formula to retrieve these data from the database.
i was just wondering if there is an easier way, i.e. without hiding the rows, adding a macro, etc., to hide the zero values from the chart.
i would like to create macros that would automatically retrieve the data and plot them on charts... the problem is i'm not that familiar and experienced vb programmer. i can only write simple procedures.
perhaps i'll just start from scratch and create the report.
thanks.
Here is a macro that will look at every chart on a worksheet and delete the formulas from those cells where the formula returns an empty string. By deleting the formulas, a pie chart won't display the 0 in the data label. You will still see that age range in the legend, however.
***Note: the macro parses the series formula using a comma as a separator. You will get an error if the worksheet name contains a comma or if the chart uses a compound range.***
To install a sub in a regular module sheet:
1) ALT + F11 to open the VBA Editor
2) Use the Insert...Module menu item to create a blank module sheet
3) Paste the suggested code in this module sheet
4) ALT + F11 to return to the spreadsheet
To run a sub or macro:
5) ALT + F8 to open the macro window
6) Select the macro
7) Click the "Run" button
Optional steps to assign a shortcut key to your macro:
8) Repeat steps 5 & 6, then press the "Options" button
9) Enter the character you want to use (Shift + character will have fewer conflicts with existing shortcuts)
10) Enter some descriptive text telling what the macro does in the "Description" field
11) Click the "OK" button
If the above procedure doesn't work, then you need to change your macro security setting. To do so, open the Tools...Macro...Security menu item. Choose Medium, then click OK.
Brad
Business Accounts
Answer for Membership
by: jppintoPosted on 2009-11-01 at 07:08:15ID: 25713909
It's not possible to do without VBA code...
e.com/Soft ware/Offic e_Producti vity/ Offic e_Suites/M S_Office/E xcel/Q_211 13454.html
With VBA code, here's a post where this was handled:
http://www.experts-exchang
Sorry, but without macros it's not possible, even in 2007 version.
jppinto