| View previous topic :: View next topic |
| Author |
Message |
kenmac General User

Joined: 25 Feb 2005 Posts: 30 Location: Perth, Western Australia
|
Posted: Fri Feb 25, 2005 11:00 pm Post subject: Problem using IF |
|
|
Hi folks,
I use 1.1.4
The following example describes the problem:
2 cells (a1, b1) are used for number entry.
Cell c1 displays the sum of a1 and b1. ( =a1+b1 )
If no data is present in a1, b1 then cell c1 displays #VALUE!
As I would rather it display a 0 , I decided to use a conditional formula.
So, I changed c1 to be =IF(a1=0,0,a1+b1).
This should have forced c1 to show 0 when a1 is empty.
Wrong!
It displays #NAME?
????
Does anyone know what is happening here?
Is there a format action that I have missed?
It works on other spreadsheets (MSWorks, Excel, etc)
kenmac |
|
| Back to top |
|
 |
8daysaweek.co.uk Super User


Joined: 29 Nov 2003 Posts: 2130 Location: UK
|
Posted: Sat Feb 26, 2005 1:18 am Post subject: |
|
|
Try semi-colons instead of commas
To test for "no data" I would probably test if a1="" rather than testing if a1=0 - but as you say it works in Works and Excel then you're probably OK
BFN, _________________ James
www.8daysaweek.co.uk - A User-Focused OOo site |
|
| Back to top |
|
 |
kenmac General User

Joined: 25 Feb 2005 Posts: 30 Location: Perth, Western Australia
|
Posted: Sat Feb 26, 2005 1:33 am Post subject: |
|
|
Ah !
You are correct.
I didn't pick up on the use of semicolons when I checked the Help info.
Thanks for that.
kenmac |
|
| Back to top |
|
 |
|