2

I tried the below Formula to calculate the time between the start time and end time in hours but not working properly.

=IF(ISBLANK([Column2]),"0",TEXT([Column2]-[Column1],"h"))** 

I have a SharePoint list with two columns Start Time and end time. I want the Formula to calculate the time between the start time and end time in hours only. If the end time is still pending (empty) value should be 0.

the table shows that in the time difference column, the total is 20 but this is not correct should be 56 hours

table

1 Answer 1

2

Try using this formula:

=IF(ISBLANK([Column2]),"0",TEXT([Column2]-[Column1],"hh")) 

Note:

  1. Sometimes comma(,) does not work in formula (it is based on language or regional settings on your site). So in that case use semicolon(;) instead of comma(,).
  2. Use correct display names of your columns in the formula.

Official Documentations:

  1. Calculated Field Formulas
1

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.