How to check the condition before the chart is being plotted?

P

Parumuga

How to check the condition before the chart is being ploted?

For example:

I need to check the value in the cell “A1â€. if the value in the cell A1 is
“1†, I need to plot the chart data that is present in the column B1 to
B2.If the value in the cell “A1†is “0â€, then do not plot the chart.

How to do that.? Any ideas on this?
 
B

Bernard Liengme

=IF(A1=1,B1,NA())
or just
=IF(A1,B1,NA()) since Excel will take 1 as true and 0 as false
best wishes
 
P

Parumuga

Hi Bernard,

Thanks for your response. Where shall I use this formula?

I tried to use this formula in the sources data dialog box of the Chart, in
the Data range? But it is not allowing me saying, “Reference is not validâ€.
Please provide me alternative solution or approach or suggestions?

Regards,
 
B

Bernard Liengme

I assumed the B column held the y-values of you chart
Put the formula I gave in C or any other column and use it as the y-values.
Send me the file (to my private email , not to the newsgroup) and I will
return it with added formula
best wishes
 

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