Ungroup selected Rows with macro/vba

mail2khalsa

New Member
Joined
Aug 23, 2014
Messages
5
Hello,


have got data more than 1800 rows and applied 35 grouping's to it (rows count isn't same for these grouping's)


Now, I want to ungroup one (of my choice) of 35 groups & I wouldn't mind if it allows one at a time while sheet remain protected all the time...


any advise on this would be appreciated....




Thanks
mail2khalsa
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
Simply...

Code:
Selection.Rows.Ungroup
 
Upvote 0
not working for me.. it's more of clicking on + manually than runnning a VBA and how will identify the rows that I want to ungroup with the below coding?

No. You only have to group some rows, select them again, copy/paste the code in VBA and run it. That's all I did for testing.
 
Upvote 0
- Why do you say "than running a VBA" if you ask for VBA in your topic title?
- "how will identify the rows that I want to ungroup with the below coding": selected rows (look at Selection in the code). Again, you ask for it in the topic title...
- Clicking the + sign will always give the same result. If you want something different, you will need a VBA-code. For example, doing an action on the currently selected rows.
 
Upvote 0

Forum statistics

Threads
1,223,248
Messages
6,171,027
Members
452,374
Latest member
keccles

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