for example i have a group of 2 rectangles, a group of 3 circles. i then make a single group of these two groups. now when i ungroup i get 2 groups. i want to ungroup in such a way, that the objects get ungrouped totally without any native groups. i know if i do the ungroup command again i'll get what i want. but is there a quicker way?

You can ask in scripting if there's a way to do a loop to ungroup nested groups. You can assign any keyboard shortcut to a script that you like, so you could either have the regualr shorcut reassigned, or have the best of both worlds and have two shorcuts, one for total groupd destruction, and one for simple fractures.

@Marijan – I see one potential problem with that script: how to deal with groups that are inserted into text frames and therefor cannot be ungrouped?Anchored groups seem to be a problem. The script will throw an error: "Invalid object for this request".

And another one: if the selection consists of two groups, one locked, the other un-locked, the script will throw an error as well: "Invalid parameter".

But there is also a side effect I consider as cool: if it happens to be that there is a group that is locked (and that is all you selected), you'll get that group not only un-grouped, but also all parts of it are locked (again ?) after script execution.

So instead of trying to debug the script, I wrote another one with a different concept in mind:

1. count all pageItems of your selection and2. try to invoke the menu command for "ungroup" that many timesIn case the menu command is not available anymore, break the loop

I think I saw a difference of output, if my script is used in InDesign CS5.5 against CS6:In CS5.5 a locked group will be un-grouped, all items formerly in that group will be locked after executionIn CS6 a locked group will be un-grouped, but all items stay un-locked (like they were, before beeing grouped)

A selection of one single group that consists of only one single object. But that is nothing you can "achieve" in the normal UI of InDesign; a group has to consist by at least two page items. However by scripting you can get a group with only one page item inside.

Name it with a .jsx suffix, that indicates the script is of JavaScript flavour and put it (in case of my script) into the Scripts/Scripts Panel folder. After that you can instantly access the script in the Scripts Panel of InDesign. Double-click the script there and it will instantly execute.

You can add subfolders to the "Scripts Panel" folder to organize your scripts.