I just played around a bit. Blank cells do not kick off this issue, they are
ignored. Negative cells, zeros, and cells containing text raise the warning,
but only once per chart. Your "blank" cell is probably a formula that
returns "", which is text. What I found more unsettling than this message is
that text cells and zeros are plotted as a marker with a value equal to the
log axis minimum; however, a quick check shows that this display of text and
zero at the log axis minimum been corrected in Excel 2007 SP1.
DisplayBlanksAs only affects truly blank cells, not "".
- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
Peltier Technical Services, Inc. -
http://PeltierTech.com
_______
"Newsx" wrote in message
...
I'm trying to put together a piece of code in Excel, to be called by an
external application to regenerate graphs.
The offending code is this:
ActiveChart.PlotVisibleOnly = True
ActiveChart.DisplayBlanksAs = xlNotPlotted
ActiveChart.Axes(xlValue).ScaleType = xlLogarithmic
The process fails when trying to set the scaletype to logarithmic,
claiming that negative or zero values cannot be plotted.
There are no negative or zero values in the data series but there are a
number of blank cells. This works perfectly in Excel 2003 but Excel 2007
throws errors.
This is really doing my head in, so any pointers would be much
appreciated!
--
Confidence is what you have when you don't understand the situation