Get sum of cells containing "Vacation" and sum by hours

Patricija

New Member
Joined
Jun 5, 2024
Messages
4
Office Version
  1. 365
Platform
  1. Windows
Hello everyone.

I would need your help. We have an excel table where employees enter their hours, sick days and holidays. Unfortunately, holidays and sick days are not entered in hours, but in words. I need this in hours for the calculation of hours. Is there a formula where I would detect the word VECATION from the list (only one column) and add it together in hours.
So one vacation is 8 hours.

For example: he had 11 days of vacation, which is 88 hours.

I need a formula that will calculate 88 hours from the word Vecation at the end.
Thank you.
1717579470754.png
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
=countif()
would do that and times by 8/24
cant see what range you are using

example
=COUNTIF(D1:D24,"vacation")*8/24
format cell as [H]:MM

you have vacation in image - but vecation in text , is that a typo

Book7
ABCDEF
1
2vacation40:00
3vacation
4vacation
5
6
7
8vacation
9
10
11
12
13
14
15vacation
16
17
18
19
Sheet1
Cell Formulas
RangeFormula
F2F2=COUNTIF(D1:D24,"vacation")*8/24
 
Upvote 0
=countif()
would do that and times by 8/24
cant see what range you are using

example
=COUNTIF(D1:D24,"vacation")*8/24
format cell as [H]:MM

you have vacation in image - but vecation in text , is that a typo

Book7
ABCDEF
1
2vacation40:00
3vacation
4vacation
5
6
7
8vacation
9
10
11
12
13
14
15vacation
16
17
18
19
Sheet1
Cell Formulas
RangeFormula
F2F2=COUNTIF(D1:D24,"vacation")*8/24
Hey.

The range is AJ11:AJ43.
Yes, it's in text. When employees have a day off, they write me a leave for that day in a word. And that I don't need to calculate the time. I would arrange a formula that detects the word vacation and calculates in hours.
 
Upvote 0
so instead of
=COUNTIF(D1:D24,"vacation")*8/24
then use your range
=COUNTIF(AJ11:AJ43,"vacation")*8/24
 
Upvote 0
yes as i said you need to format the cell as TIME using [H]:MM
0.33333333 is the fraction of 1 that will be displayed as time
ie 3rd of 1 = 1/3 of 25 hrs = 8

OK , see you have solved to get a value
you are welcome
 
Upvote 0

Forum statistics

Threads
1,223,891
Messages
6,175,229
Members
452,621
Latest member
Laura_PinksBTHFT

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