If function sees 0 as false?

dodgeking3171

New Member
Joined
Feb 6, 2014
Messages
39
Hey Guys, have a quick question,

I made a spread sheet a year or so ago, and in it i use this basic formula =if(a1,a1,a2) The purpose was this, im either pulling a price from one price list or another. So lets assume the values are this

a1=1
a2=3
The result is 1

a1=0(or blank)
a2=3
The Result is 3

now obviously in the formula does not set a arguement like =if (a1>0,a1,a2) So my question is this, does the IF statement always see 0 as a false statement if its not told to see it as a true statement?

This seems basic, and it show i set up my whole spreadsheet a few years ago. but now i dont quite remember why i set it that way and im just making sure that in the future it wont cause a problem with another formula.

Thanks guys
 

Some videos you may like

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December

wigi

Well-known Member
Joined
Jul 10, 2006
Messages
7,958
Office Version
  1. 365
Platform
  1. Windows
  2. Mobile
  3. Web
Yes, 0 and a blank cell will lead to FALSE. You will need to specify your condition in a better way than this.
 

Watch MrExcel Video

Forum statistics

Threads
1,123,258
Messages
5,600,567
Members
414,389
Latest member
MarkElla

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top