Search the Day Off Dates in a Given ROW

Armstrong_N14

Board Regular
Joined
Aug 19, 2023
Messages
85
Office Version
  1. 365
Platform
  1. Windows
Good Day Team

Any suggestions on how can I Find the dates that show Days Off in a given row? I can't use XLBB due to restrictions.

A1SunMonTueWedThuFriSat
A2Agent NameShift StartShift End09/1/202309/2/202309/3/202309/04/202309/05/202309/06/202309/07/2023Days OFF
A3Employee 100:0009:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFFOFF
A4Employee 200:0009:00OFF00:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFF
A5Employee 300:0009:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFFOFF
A6Employee 400:0009:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFFOFF

I tried using the match formula but it only returns the first date that is on OFF. I was trying to see if searching from right to left may do it but I cant get the right formula. Please help. Thanks in advance
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
Like this?

1693521035754.png


K3
Excel Formula:
=IF(D3="OFF", D1, "") & IF(E3="OFF", " " & E1, "") & IF(F3="OFF", " " & F1, "") & IF(G3="OFF", " " & G1, "") & IF(H3="OFF", " " & H1, "") & IF(I3="OFF", " " & I1, "") & IF(J3="OFF", " " & J1, "")

K4
Excel Formula:
=IF(D4="OFF", D1, "") & IF(E4="OFF", " " & E1, "") & IF(F4="OFF", " " & F1, "") & IF(G4="OFF", " " & G1, "") & IF(H4="OFF", " " & H1, "") & IF(I4="OFF", " " & I1, "") & IF(J4="OFF", " " & J1, "")

K5
Excel Formula:
=IF(D5="OFF", D1, "") & IF(E5="OFF", " " & E1, "") & IF(F5="OFF", " " & F1, "") & IF(G5="OFF", " " & G1, "") & IF(H5="OFF", " " & H1, "") & IF(I5="OFF", " " & I1, "") & IF(J5="OFF", " " & J1, "")

K6
Excel Formula:
=IF(D6="OFF", D1, "") & IF(E6="OFF", " " & E1, "") & IF(F6="OFF", " " & F1, "") & IF(G6="OFF", " " & G1, "") & IF(H6="OFF", " " & H1, "") & IF(I6="OFF", " " & I1, "") & IF(J6="OFF", " " & J1, "")
 
Upvote 0
Try this:
this had errors. trying to update. Sorry.

You have me confused 9/1/2023 is not a SUNDAY!
 
Last edited:
Upvote 0
You're welcome, best wishes.
Here is the corrected version, with day of week in the header column to show you why I was confused:

Mr excel questions 58.xlsm
ABCDEFGHIJK
1SunMonTueWedThuFriSat
2Agent NameShift StartShift EndFri 2023-09-01Sat 2023-09-02Sun 2023-09-03Mon 2023-09-04Tue 2023-09-05Wed 2023-09-06Thu 2023-09-07Days OFF
3Employee 100:0009:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFFOFFWed, Thu
4Employee 200:0009:00OFF00:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFF00:00 - 09:00, OFF
5Employee 300:0009:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFFOFF00:00 - 09:00, OFF
6Employee 400:0009:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:0000:00 - 09:00OFFOFFOFF, OFF
Armstrong_N14
Cell Formulas
RangeFormula
E2:J2E2=D2+1
K3:K6K3=TEXTJOIN(", ",,TEXT(FILTER(D2:J2,(D3:J3="OFF")),"ddd"))
 
Upvote 0
Solution

Forum statistics

Threads
1,215,167
Messages
6,123,401
Members
449,098
Latest member
ArturS75

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