IF Statement question

D

Doug Mc

What is the matter with this IF statement? It shows zero rather than the
contents of N111

=IF(N1='GRO/INC',N111,0)

Thanks,
Doug
 
V

Vasant Nanavati

Hi Doug:

Try enclosing "GRO/INC" in double quotes.

For some reason that I don't fully understand, when I tried it with single
quotes, I got a circular reference. Very strange.

Regards,

Vasant.
 
D

Doug Mc

Thanks guys,

That made it work ok when true; it returned the correct amount; but.......
When it was false, and should have returned zero, it returned some other
number - I don't know where from...

Any ideas?
Doug
 
M

Michael Tomasura

Make sure the cell is formated as a number
--

Doug Mc said:
Thanks guys,

That made it work ok when true; it returned the correct amount; but.......
When it was false, and should have returned zero, it returned some other
number - I don't know where from...

Any ideas?
Doug
 
E

Eric

Hmmm, I guess N1 does not equal "GRO/INC and it's
returning the value of zero. It's doing exactly what it's
written to do.

By the way,if some knows how to make an IF function do
nothing if a logical expresion is false (meaning not
changing the data in the cell)please e-mail me with the
solution.
 

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