Hello,

i have a list of items organized in : project, activities and sub-activities (Column "A"). They have a specific index - level number, Project = 0, Activity = 1, Sub-activity = 2. These numbers are in column "B".

The data looks like this :

Column "A"

Example Project
Activity 1
Sub-activity 1
Sub-activity 2
Activity 2

Column "B"

0
1
2
2
1

What i would like to have is, when the macro runs, all the level 2 should group under the level 1 and all the level 1 (with the level 2 grouped) should group under level 0.