I am trying to write a formula from the data in columns A to E which finds the maximum "Date To" where a "Staff" is the same and "Activity Code" is the same in a consecutive run of days in "Date To" column, then place answer into the "End" column. I have provide the expected output in the "End" column. Refer file or screenshot.
Appreciate any help here.
Regards
GB

Appreciate any help here.
Regards
GB
