angeloudaki
New Member
- Joined
- Jul 7, 2015
- Messages
- 46
Working out time.
How do I use a column to calculate only if a cell contains specific criteria? e.g. Only calculate difference between start and end time if the category is "Accrued" otherwise use "0"
[TABLE="width: 400"]
<colgroup><col width="80" span="5" style="width:48pt"> </colgroup><tbody>[TR]
[TD="class: xl65, width: 80"]Category[/TD]
[TD="class: xl65, width: 80"]Start[/TD]
[TD="class: xl65, width: 80"]End[/TD]
[TD="class: xl65, width: 80"]Accrued[/TD]
[TD="class: xl65, width: 80"]Used[/TD]
[/TR]
[TR]
[TD="class: xl66"]Accrued[/TD]
[TD="class: xl67"]09:25[/TD]
[TD="class: xl67"]09:40[/TD]
[TD="class: xl68"]00:15[/TD]
[TD="class: xl65"]0[/TD]
[/TR]
[TR]
[TD="class: xl66"]Used[/TD]
[TD="class: xl67"]16:00[/TD]
[TD="class: xl67"]17:00[/TD]
[TD="class: xl65"] 0[/TD]
[TD="class: xl68"]01:00[/TD]
[/TR]
</tbody>[/TABLE]
I tried an 'If' but I can't make it work
How do I use a column to calculate only if a cell contains specific criteria? e.g. Only calculate difference between start and end time if the category is "Accrued" otherwise use "0"
[TABLE="width: 400"]
<colgroup><col width="80" span="5" style="width:48pt"> </colgroup><tbody>[TR]
[TD="class: xl65, width: 80"]Category[/TD]
[TD="class: xl65, width: 80"]Start[/TD]
[TD="class: xl65, width: 80"]End[/TD]
[TD="class: xl65, width: 80"]Accrued[/TD]
[TD="class: xl65, width: 80"]Used[/TD]
[/TR]
[TR]
[TD="class: xl66"]Accrued[/TD]
[TD="class: xl67"]09:25[/TD]
[TD="class: xl67"]09:40[/TD]
[TD="class: xl68"]00:15[/TD]
[TD="class: xl65"]0[/TD]
[/TR]
[TR]
[TD="class: xl66"]Used[/TD]
[TD="class: xl67"]16:00[/TD]
[TD="class: xl67"]17:00[/TD]
[TD="class: xl65"] 0[/TD]
[TD="class: xl68"]01:00[/TD]
[/TR]
</tbody>[/TABLE]
I tried an 'If' but I can't make it work