Determine which values are = 0 & create string

L

lecoughlin

Hi all,
I have a list of items & values in two columns.... for example

Apple 3
Banana 0
Pear 5
Orange 8
Grapefruit 0

At the bottom of the list, I want to have a cell that will say which
values are zero. For example:

"You have no bananas, grapefruit"

If apple was also = 0 it would say "You have no apples, bananas,
grapefruit"

Is there a way to do this without VBA code? Is it just going to be a
crazy IF statement?
 
P

Pete_UK

Why have you made apple and banana plural in your text comment at the
bottom, but not grapefruit? Not all words are made plural by adding an
s to the end, eg potato, so this can be a problem to achieve.

How many rows of data do you have in your real data?

Pete
 
L

lecoughlin

Sorry, disregard the plurals. I made up that example to simplify my
question - it shouldn't be a problem with the real data.

There are 9 rows that I would have to check if the value is zero.
Basically I want a statement that will say (if any of the 9 are = 0)
-- The following costs are excluded from this scenario: .......
 

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

Similar Threads


Top