Question about replacing "railroad" or multiple ######'s with a blank cell

robpertraymond

New Member
Joined
Sep 25, 2014
Messages
5
I'm having trouble with a formula for a sign-in/out spreadsheet that tracks hours:

For each individual person I have 2 sign-in and 2 sign-out times (in case they sign in and out multiple times in a day). I have this formula: (sign out 1 - sign in 1) + (sign out 2 - sign in 2) for the total hours cell OR =(D3-C3)+(F3-E3).

The problem is that when someone signs in, before they sign back out, I get a ###### error message in the 'total' hours cell because it is referring empty cells. It is only resolved when I add a sign-out time. I tried to add this formula in the 'total' cell: =IFERROR((D3-C3)+(F3-E3), "") but I get an error message that reads "Inconsistent formula". My goal is to make it so that when someone signs in, instead of seeing the ###### error message in the 'total' cell until they sign back out, the 'total' cell has a blank string (" ") or even changes to a different color until a sign-out time is entered.

Any help is appreciated, thanks!
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Hmmm that seems to work to insert an empty string in place of the ######'s, but it stays empty when when I add a sign-out time.

What is that function doing exactly?
 
Upvote 0
Hmmm that seems to work to insert an empty string in place of the ######'s, but it stays empty when when I add a sign-out time.

What is that function doing exactly?
It looks to see if either C3 or E3 is blank... if either one is, it outputs the empty string (""). So, the only way a value is output is if, at minimum, both C3 and E3 have values in them. You will note that I originally introduced the formula by saying "Maybe this"... I really am not sure under what circumstance you want values displayed and under what circumstances you want "" displayed
 
Upvote 0

Forum statistics

Threads
1,214,592
Messages
6,120,433
Members
448,961
Latest member
nzskater

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