Formula issues getting blank rather than zero

Detectiveclem

Active Member
Joined
May 31, 2014
Messages
320
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
  2. MacOS
What am I doing wrong

I am using this formula in cell E7 successfully =IF(D7-C7<0, 1+D7-C7, D7-C7).

But when cell C7 has no data I do NOT want ‘0’ to appear in E7. I have tried various formulas including this one =IF(C7=””,””,D7-C7<0, 1+D7-C7, D7-C7) but it doesn’t work.

Can someone please help me rectify the formula so that cell E7 remains blank until data is entered in C7.

Thank you
 
Oops, wasn't thinking. It should be
=IF(AND(M23="",O23=""),"",IF(M23="",-O23,M23-O23))
 
Upvote 0

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
You are a genius, everything works perfectly. Sorry for taking up so much of your time but very much appreciated.
 
Upvote 0

Forum statistics

Threads
1,223,214
Messages
6,170,771
Members
452,353
Latest member
strainu

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
Back
Top