# Can Any one here help me with IF(Blank question

#### tazmtiger777

##### New Member
Hi
I have this formula to calculate minutes in the J column for each row with values, and it starting with J10.

Example:
"=IF(I10>H10,I10-H10,I10+1-H10)" It returns the difference between two values in Cell I10 and H10 to Cell J10 (all good there!)

My question is:
How can I tell the example formula above to ignore placing any values in the J10 if any of the corresponding values in the H10 to I10 are left blank.

In other words, if there in no value in any calculation "called by a corresponding cells in "J column" ……. How do I tell it to display no value, or leave the target cell blank?
Rather than placing the default value of my calculation "which is 1440." That gets rather messy since I have many rows that may be skipped in between with no value, or rows that have no input at all. And since my formula returns a default value of 1440, it adds that to may totals for each blank line left without inputs.

I just need each corresponding cell to return a value as indicated in row by the cell in column J, --->Only if corresponding cells in "H or I columns" have a typed-in value in them and are not left blank?

But want the corresponding cell to stay blank IN COLUMN J "if any cell it calls values for "has been left blank, or has no value in it."

(Example: On Cell J10 I have "=IF(I10>H10,I10-H10,I10+1-H10)" <-- It asks to return the difference between two cells that contain time values in them and it returns the difference between the two time values to J10) But when J10 asked values are left blank, it automatically returns 1440 in the J10 cell.

Hope I make sense.

Thank you in advance to anyone that can provide me any assistance with my question.

### Excel Facts

To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.

#### JamesCanale

##### Board Regular
=if(or(i10="",h10=""),"",YOURFORMULA)

#### tazmtiger777

##### New Member
=if(or(i10="",h10=""),"",YOURFORMULA)
James,
Thank you so much lighting speed assistance, that did the trick. Great job!!

Replies
13
Views
195
Replies
1
Views
63
Replies
3
Views
46
Replies
1
Views
132
Replies
5
Views
264

1,129,352
Messages
5,635,785
Members
416,882
Latest member
ericvrealty

### 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.

### Which adblocker are you using?

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

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