Data points showing for empty cells?

H

hmmm...

When I populate a worksheet column sparsely (leaving many cells blank), and
then create a line chart of the data, the null cells do not create data
points. This is what I want to happen.

However, if I want to populate the column (e.g. D) based on the existence of
values in corresponding cells in another column (e.g. C), using the
following formula in D:

=IF(C1<>"",SUM($C1+100) ,"")

the cells that are empty now create data points in the chart. Apparently ""
is not the same as an empty cell.

How can I perform my calculation in D, based on the existence of values in
corresponding cells of C, and leave empty cells in D that will not show up
as data points in my line chart.

I'm using Office 97. Thanks!
 
H

hmmm...

Thanks. I also test the contents of these cells later in VBA. If a cell is
set to #N/A, how do I test whether it is empty from VBA?
 
J

Jon Peltier

or =IF(C1<>"",$C1+100,NA())

You don't need to put the small formula inside the SUM function, and you
should specify the #N/A error with NA().

To look for the error, try WorksheetFunction.IsNA(arg)

- Jon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top