Is there a way to Group/Ungroup specific columns using a macro? I want to be able to Group/Ungroup several different column groups (see attached).
There are two problems, firstly I don't want the gaps between the groups, i.e. I don't want columns D, I and L but without them it is not possible to group in this way because it will just make a single group rather than multiple groups.
Secondly I would want a different keyboard shortcut for each group so I can be specific about which group to show/hide?
If this is not possible would a better alternative be to simply achieve the same thing using Hide/Unhide? If so, is it possible to achieve the Hide/Unhide by clicking on a particular cell, in the sample attached perhaps double clicking on A1 to hide Group 1, E1 to hide Group 2 and so on. I'm not sure how Unhide would then work, so maybe a toggle would be better, say Ctrl J toggles Group 1 on and off and then Ctrl M toggles Group 2 on and off. Buttons on the page won't really work owing to the size of the main sheet.
Unsure if this is even possible...
Many thanks
Bookmarks