Organise Roster Columns by Start Times

KentC

New Member
Joined
Jan 19, 2023
Messages
1
Office Version
  1. 2019
Platform
  1. Windows
Good morning everyone

I work for an animal-related charity. We have a long, complicated roster developed in Excel that can be difficult to manage.

Volunteer shifts are divided by days (7 columns) and extend to over 100 rows. I need to be able to order the rows by start times, which are given in 24-hour format. However, the cells each contain a big, undifferentiated block of data indicating the volunteer's individual number (eg SP123), their respective start time (eg 14:30) and their job location and type for that day (eg 8219).

How do I create a formula that will 'see' the start time in each cell and allow me to order those start times within individual columns indicating days? I want to be able to instantly see the earliest Monday shift, followed in the next row by the second-earliest, then the third-earliest, and so on. The last row should show the latest shift of that particular day.

Please find attached a sample of the roster.

Many thanks, Kent

Sample Book.xlsx
ABCDEFGH
1SUNMONTUEWEDTHUFRISAT
21OR SP705 14:13 PilotSP323 14:19 9029SP043 14:35 8237SP118 14:25 8077SP416 14:51 8419OR
300:0008:4008:1108:0008:2308:0000:00
42OR SP213 03:22 8904SP517 03:11 8272SP518 03:35 SG 8213OR SP018 03:10 SG 8207SP545 03:10 0177
500:0008:0008:0008:0000:0008:0008:00
63SP411 13:24 8417SP240 13:45 8759SP239 13:31 8757SP039 13:31 8127SP237 13:25 SG 8755OR OR
708:0008:0808:0008:2708:0000:0000:00
84OR OR SP614 07:00 9934SP524 06:54 0177SP226 07:11 8717SP228 07:45 8721SP548 08:25 0177
900:0000:0008:0008:0008:0008:0008:00
105SP206 10:29 8739SP615 10:00 9934OR SP232 11:29 8745SP533 12:00 SG 0177SP036 11:55 8123OR
1108:2308:0000:0008:0008:0008:0000:00
126OR SP112 03:25 8006SP021 03:48 8201OR SP516 00:05 0177SP610 03:00 9934SP544 00:05 0177
1300:0008:0008:0000:0008:0008:0008:00
147SP109 15:10 8089SP326 16:14 8331OR OR SP246 14:22 8761SP248 14:50 8797SP430 15:42 8421
1508:0408:0000:0000:0008:0008:0008:00
168OR SP013 01:54 7204SP014 01:55 7216SP016 01:56 7210SP608 02:00 9934SP212 02:56 8701OR
1700:0008:0008:1108:0008:0006:0000:00
189OR SP532 11:47 0177SP116 12:04 8023SP233 12:18 8935OR SP234 12:21 8749SP262 10:45 8739
1900:0008:0008:0008:0300:0008:0008:00
2010SP203 05:58 8717SP614 07:00 9934SP524 06:54 0177SP028 06:50 8205SP523 06:42 0177OR OR
2108:0008:0008:0008:0008:0000:0000:00
Sheet1
Cells with Conditional Formatting
CellConditionCell FormatStop If True
E14Expression=SEARCH("*Annual*",H123)textNO
E14Expression=SEARCH("*REST*",H123)textNO
E14Expression=SEARCH("* SP*",H123)textNO
E14Expression=SEARCH("*OR*",H123)textNO
D10Expression=SEARCH("*Annual*",B113)textNO
D10Expression=SEARCH("*REST*",B113)textNO
D10Expression=SEARCH("* SP*",B113)textNO
D10Expression=SEARCH("*OR*",B113)textNO
B4Expression=SEARCH("*Annual*",F247)textNO
B4Expression=SEARCH("*REST*",F247)textNO
B4Expression=SEARCH("* SP*",F247)textNO
B4Expression=SEARCH("*OR*",F247)textNO
D16Expression=SEARCH("*Annual*",#REF!)textNO
D16Expression=SEARCH("*REST*",#REF!)textNO
D16Expression=SEARCH("* SP*",#REF!)textNO
D16Expression=SEARCH("*OR*",#REF!)textNO
H18Expression=SEARCH("*Annual*",#REF!)textNO
H18Expression=SEARCH("*REST*",#REF!)textNO
H18Expression=SEARCH("* SP*",#REF!)textNO
H18Expression=SEARCH("*OR*",#REF!)textNO
E2Expression=SEARCH("*Annual*",#REF!)textNO
E2Expression=SEARCH("*REST*",#REF!)textNO
E2Expression=SEARCH("* SP*",#REF!)textNO
E2Expression=SEARCH("*OR*",#REF!)textNO
F4Expression=SEARCH("*Annual*",B211)textNO
F4Expression=SEARCH("*REST*",B211)textNO
F4Expression=SEARCH("* SP*",B211)textNO
F4Expression=SEARCH("*OR*",B211)textNO
D2Expression=SEARCH("*Annual*",#REF!)textNO
D2Expression=SEARCH("*REST*",#REF!)textNO
D2Expression=SEARCH("* SP*",#REF!)textNO
D2Expression=SEARCH("*OR*",#REF!)textNO
B20Expression=SEARCH("*Annual*",#REF!)textNO
B20Expression=SEARCH("*REST*",#REF!)textNO
B20Expression=SEARCH("* SP*",#REF!)textNO
B20Expression=SEARCH("*OR*",#REF!)textNO
G8Expression=SEARCH("*Annual*",#REF!)textNO
G8Expression=SEARCH("*REST*",#REF!)textNO
G8Expression=SEARCH("* SP*",#REF!)textNO
G8Expression=SEARCH("*OR*",#REF!)textNO
E18Expression=SEARCH("*Annual*",E225)textNO
E18Expression=SEARCH("*REST*",E225)textNO
E18Expression=SEARCH("* SP*",E225)textNO
E18Expression=SEARCH("*OR*",E225)textNO
H16Expression=SEARCH("*Annual*",B11)textNO
H16Expression=SEARCH("*REST*",B11)textNO
H16Expression=SEARCH("* SP*",B11)textNO
H16Expression=SEARCH("*OR*",B11)textNO
C10Expression=SEARCH("*Annual*",XEY145)textNO
C10Expression=SEARCH("*REST*",XEY145)textNO
C10Expression=SEARCH("* SP*",XEY145)textNO
C10Expression=SEARCH("*OR*",XEY145)textNO
C4Expression=SEARCH("*Annual*",C99)textNO
C4Expression=SEARCH("*REST*",C99)textNO
C4Expression=SEARCH("* SP*",C99)textNO
C4Expression=SEARCH("*OR*",C99)textNO
D18Expression=SEARCH("*Annual*",D129)textNO
D18Expression=SEARCH("*REST*",D129)textNO
D18Expression=SEARCH("* SP*",D129)textNO
D18Expression=SEARCH("*OR*",D129)textNO
F14Expression=SEARCH("*Annual*",F129)textNO
F14Expression=SEARCH("*REST*",F129)textNO
F14Expression=SEARCH("* SP*",F129)textNO
F14Expression=SEARCH("*OR*",F129)textNO
F6Expression=SEARCH("*Annual*",F185)textNO
F6Expression=SEARCH("*REST*",F185)textNO
F6Expression=SEARCH("* SP*",F185)textNO
F6Expression=SEARCH("*OR*",F185)textNO
G16Expression=SEARCH("*Annual*",G261)textNO
G16Expression=SEARCH("*REST*",G261)textNO
G16Expression=SEARCH("* SP*",G261)textNO
G16Expression=SEARCH("*OR*",G261)textNO
F10Expression=SEARCH("*Annual*",F65)textNO
F10Expression=SEARCH("*REST*",F65)textNO
F10Expression=SEARCH("* SP*",F65)textNO
F10Expression=SEARCH("*OR*",F65)textNO
C6Expression=SEARCH("*Annual*",C293)textNO
C6Expression=SEARCH("*REST*",C293)textNO
C6Expression=SEARCH("* SP*",C293)textNO
C6Expression=SEARCH("*OR*",C293)textNO
G6Expression=SEARCH("*Annual*",G293)textNO
G6Expression=SEARCH("*REST*",G293)textNO
G6Expression=SEARCH("* SP*",G293)textNO
G6Expression=SEARCH("*OR*",G293)textNO
F12Expression=SEARCH("*Annual*",F149)textNO
F12Expression=SEARCH("*REST*",F149)textNO
F12Expression=SEARCH("* SP*",F149)textNO
F12Expression=SEARCH("*OR*",F149)textNO
E6Expression=SEARCH("*Annual*",E245)textNO
E6Expression=SEARCH("*REST*",E245)textNO
E6Expression=SEARCH("* SP*",E245)textNO
E6Expression=SEARCH("*OR*",E245)textNO
E10Expression=SEARCH("*Annual*",E285)textNO
E10Expression=SEARCH("*REST*",E285)textNO
E10Expression=SEARCH("* SP*",E285)textNO
E10Expression=SEARCH("*OR*",E285)textNO
C14Expression=SEARCH("*Annual*",C129)textNO
C14Expression=SEARCH("*REST*",C129)textNO
C14Expression=SEARCH("* SP*",C129)textNO
C14Expression=SEARCH("*OR*",C129)textNO
H2Expression=SEARCH("*Annual*",H209)textNO
H2Expression=SEARCH("*REST*",H209)textNO
H2Expression=SEARCH("* SP*",H209)textNO
H2Expression=SEARCH("*OR*",H209)textNO
B10Expression=SEARCH("*Annual*",#REF!)textNO
B10Expression=SEARCH("*REST*",#REF!)textNO
B10Expression=SEARCH("* SP*",#REF!)textNO
B10Expression=SEARCH("*OR*",#REF!)textNO
B2Expression=SEARCH("*Annual*",D269)textNO
B2Expression=SEARCH("*REST*",D269)textNO
B2Expression=SEARCH("* SP*",D269)textNO
B2Expression=SEARCH("*OR*",D269)textNO
C16Expression=SEARCH("*Annual*",C239)textNO
C16Expression=SEARCH("*REST*",C239)textNO
C16Expression=SEARCH("* SP*",C239)textNO
C16Expression=SEARCH("*OR*",C239)textNO
H12Expression=SEARCH("*Annual*",H297)textNO
H12Expression=SEARCH("*REST*",H297)textNO
H12Expression=SEARCH("* SP*",H297)textNO
H12Expression=SEARCH("*OR*",H297)textNO
H8Expression=SEARCH("*Annual*",H13)textNO
H8Expression=SEARCH("*REST*",H13)textNO
H8Expression=SEARCH("* SP*",H13)textNO
H8Expression=SEARCH("*OR*",H13)textNO
E20Expression=SEARCH("*Annual*",E187)textNO
E20Expression=SEARCH("*REST*",E187)textNO
E20Expression=SEARCH("* SP*",E187)textNO
E20Expression=SEARCH("*OR*",E187)textNO
G12Expression=SEARCH("*Annual*",G79)textNO
G12Expression=SEARCH("*REST*",G79)textNO
G12Expression=SEARCH("* SP*",G79)textNO
G12Expression=SEARCH("*OR*",G79)textNO
C8Expression=SEARCH("*Annual*",#REF!)textNO
C8Expression=SEARCH("*REST*",#REF!)textNO
C8Expression=SEARCH("* SP*",#REF!)textNO
C8Expression=SEARCH("*OR*",#REF!)textNO
E16Expression=SEARCH("*Annual*",E47)textNO
E16Expression=SEARCH("*REST*",E47)textNO
E16Expression=SEARCH("* SP*",E47)textNO
E16Expression=SEARCH("*OR*",E47)textNO
G4Expression=SEARCH("*Annual*",G123)textNO
G4Expression=SEARCH("*REST*",G123)textNO
G4Expression=SEARCH("* SP*",G123)textNO
G4Expression=SEARCH("*OR*",G123)textNO
D6,G2Expression=SEARCH("*Annual*",#REF!)textNO
D6,G2Expression=SEARCH("*REST*",#REF!)textNO
D6,G2Expression=SEARCH("* SP*",#REF!)textNO
D6,G2Expression=SEARCH("*OR*",#REF!)textNO
D8,G18,E4Expression=SEARCH("*Annual*",#REF!)textNO
D8,G18,E4Expression=SEARCH("*REST*",#REF!)textNO
D8,G18,E4Expression=SEARCH("* SP*",#REF!)textNO
D8,G18,E4Expression=SEARCH("*OR*",#REF!)textNO
C12Expression=SEARCH("*Annual*",#REF!)textNO
C12Expression=SEARCH("*REST*",#REF!)textNO
C12Expression=SEARCH("* SP*",#REF!)textNO
C12Expression=SEARCH("*OR*",#REF!)textNO
D12Expression=SEARCH("*Annual*",#REF!)textNO
D12Expression=SEARCH("*REST*",#REF!)textNO
D12Expression=SEARCH("* SP*",#REF!)textNO
D12Expression=SEARCH("*OR*",#REF!)textNO
B6Expression=SEARCH("*Annual*",#REF!)textNO
B6Expression=SEARCH("*REST*",#REF!)textNO
B6Expression=SEARCH("* SP*",#REF!)textNO
B6Expression=SEARCH("*OR*",#REF!)textNO
C18Expression=SEARCH("*Annual*",XEY251)textNO
C18Expression=SEARCH("*REST*",XEY251)textNO
C18Expression=SEARCH("* SP*",XEY251)textNO
C18Expression=SEARCH("*OR*",XEY251)textNO
D20Expression=SEARCH("*Annual*",D171)textNO
D20Expression=SEARCH("*REST*",D171)textNO
D20Expression=SEARCH("* SP*",D171)textNO
D20Expression=SEARCH("*OR*",D171)textNO
F16Expression=SEARCH("*Annual*",XFB189)textNO
F16Expression=SEARCH("*REST*",XFB189)textNO
F16Expression=SEARCH("* SP*",XFB189)textNO
F16Expression=SEARCH("*OR*",XFB189)textNO
G14Expression=SEARCH("*Annual*",XEZ185)textNO
G14Expression=SEARCH("*REST*",XEZ185)textNO
G14Expression=SEARCH("* SP*",XEZ185)textNO
G14Expression=SEARCH("*OR*",XEZ185)textNO
D4Expression=SEARCH("*Annual*",XEZ251)textNO
D4Expression=SEARCH("*REST*",XEZ251)textNO
D4Expression=SEARCH("* SP*",XEZ251)textNO
D4Expression=SEARCH("*OR*",XEZ251)textNO
H4Expression=SEARCH("*Annual*",XFA203)textNO
H4Expression=SEARCH("*REST*",XFA203)textNO
H4Expression=SEARCH("* SP*",XFA203)textNO
H4Expression=SEARCH("*OR*",XFA203)textNO
F20,G10Expression=SEARCH("*Annual*",#REF!)textNO
F20,G10Expression=SEARCH("*REST*",#REF!)textNO
F20,G10Expression=SEARCH("* SP*",#REF!)textNO
F20,G10Expression=SEARCH("*OR*",#REF!)textNO
H13Expression=SEARCH("*Annual*",H12)textNO
H13Expression=SEARCH("*REST*",H12)textNO
H13Expression=SEARCH("* SP*",H12)textNO
H13Expression=SEARCH("*OR*",H12)textNO
E8Expression=SEARCH("*Annual*",E247)textNO
E8Expression=SEARCH("*REST*",E247)textNO
E8Expression=SEARCH("* SP*",E247)textNO
E8Expression=SEARCH("*OR*",E247)textNO
F18Expression=SEARCH("*Annual*",B1048575)textNO
F18Expression=SEARCH("*REST*",B1048575)textNO
F18Expression=SEARCH("* SP*",B1048575)textNO
F18Expression=SEARCH("*OR*",B1048575)textNO
B18Expression=SEARCH("*Annual*",F1048575)textNO
B18Expression=SEARCH("*REST*",F1048575)textNO
B18Expression=SEARCH("* SP*",F1048575)textNO
B18Expression=SEARCH("*OR*",F1048575)textNO
D14Expression=SEARCH("*Annual*",D1048483)textNO
D14Expression=SEARCH("*REST*",D1048483)textNO
D14Expression=SEARCH("* SP*",D1048483)textNO
D14Expression=SEARCH("*OR*",D1048483)textNO
B12Expression=SEARCH("*Annual*",G1048573)textNO
B12Expression=SEARCH("*REST*",G1048573)textNO
B12Expression=SEARCH("* SP*",G1048573)textNO
B12Expression=SEARCH("*OR*",G1048573)textNO
B8Expression=SEARCH("*Annual*",B15)textNO
B8Expression=SEARCH("*REST*",B15)textNO
B8Expression=SEARCH("* SP*",B15)textNO
B8Expression=SEARCH("*OR*",B15)textNO
H10Expression=SEARCH("*Annual*",H1048573)textNO
H10Expression=SEARCH("*REST*",H1048573)textNO
H10Expression=SEARCH("* SP*",H1048573)textNO
H10Expression=SEARCH("*OR*",H1048573)textNO
G20Expression=SEARCH("*Annual*",G103)textNO
G20Expression=SEARCH("*REST*",G103)textNO
G20Expression=SEARCH("* SP*",G103)textNO
G20Expression=SEARCH("*OR*",G103)textNO
H20,C2,C20Expression=SEARCH("*Annual*",C29)textNO
H20,C2,C20Expression=SEARCH("*REST*",C29)textNO
H20,C2,C20Expression=SEARCH("* SP*",C29)textNO
H20,C2,C20Expression=SEARCH("*OR*",C29)textNO
F2Expression=SEARCH("*Annual*",F45)textNO
F2Expression=SEARCH("*REST*",F45)textNO
F2Expression=SEARCH("* SP*",F45)textNO
F2Expression=SEARCH("*OR*",F45)textNO
H14Expression=SEARCH("*Annual*",#REF!)textNO
H14Expression=SEARCH("*REST*",#REF!)textNO
H14Expression=SEARCH("* SP*",#REF!)textNO
H14Expression=SEARCH("*OR*",#REF!)textNO
B14,F8Expression=SEARCH("*Annual*",#REF!)textNO
B14,F8Expression=SEARCH("*REST*",#REF!)textNO
B14,F8Expression=SEARCH("* SP*",#REF!)textNO
B14,F8Expression=SEARCH("*OR*",#REF!)textNO
B2:H21Cell Valuecontains " SP"textNO
B2:H21Cell Valuecontains "SG"textNO
B3:H3,B17:H17,B13:G13,B5:H5,B9:H9,B11:H11,B19:H19,B7:H7,B15:H15,B21:H21Expression=SEARCH("*Annual*",B2)textNO
B2:H21Cell Valuecontains "Annual"textNO
B2:H21Cell Valuecontains "OR"textNO
B2:H21Cell Valuecontains "REST"textNO
B3:H3,B17:H17,B13:G13,B5:H5,B9:H9,B11:H11,B19:H19,B7:H7,B15:H15,B21:H21Expression=SEARCH("*REST*",B2)textNO
B3:H3,B17:H17,B13:G13,B5:H5,B9:H9,B11:H11,B19:H19,B7:H7,B15:H15,B21:H21Expression=SEARCH("* SP*",B2)textNO
B2:H21Expression=ISERROR(B2)textYES
B3:H3,B17:H17,B13:G13,B5:H5,B9:H9,B11:H11,B19:H19,B7:H7,B15:H15,B21:H21Expression=SEARCH("*OR*",B2)textNO
 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.

Forum statistics

Threads
1,223,904
Messages
6,175,295
Members
452,632
Latest member
jladair

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