Forum

Notifications
Clear all

Sort list dynamically but starting from today

4 Posts
3 Users
0 Reactions
82 Views
(@lanser)
Posts: 61
Estimable Member
Topic starter
 

Hi,

I have a list of weeks for this year is it possible to sort the list but always have the current week at the top?

From this

Week 1

Week 2

...

Week 51

Week 52

 

To:

Week 2

Week 3

...

Week 52

Week 1

 

I've google but can't find an answer its an .xlsm so a vba would be fine.

 

regards

John

 
Posted : 06/07/2023 11:46 am
Riny van Eekelen
(@riny)
Posts: 1194
Member Moderator
 

Provided your Excel version supports the rather new VSTACK and TAKE functions, you could have a look at the example in the attached file and see if it works for you.

 
Posted : 07/07/2023 1:01 am
(@lanser)
Posts: 61
Estimable Member
Topic starter
 

Awesome amazingly simple, yes I have 365 subscription and I obviously need to learn more about the new functions

 

Thanks

 
Posted : 07/07/2023 11:17 am
Philip Treacy
(@philipt)
Posts: 1629
Member Admin
 

This article explains the new Array Shaping Functions

Regards

Phil

 
Posted : 07/07/2023 8:47 pm
Share: