Ungroup a nested group
pete at lcsql.com
Sun Mar 24 18:47:24 EDT 2013
What seems to work in a script is to start editing each owning group until
you reach the one containing the group to be ungrouped, ungroup it, then
stop editing its owning group.
I'm nervous though. I've found that the world of editbackground mode is a
weird and wonderful place. No matter how many cards are in the stack being
edited, the cardIDs returns only the card that is being edited. And the
number of controls on the card is the number in the group being edited not
the number on the card. And the long id of any control in the group before
you entered this strange place isn't valid because it's not a member of the
group at that point.
lcSQL Software <http://www.lcsql.com>
On Sun, Mar 24, 2013 at 1:26 PM, Peter Haworth <pete at lcsql.com> wrote:
> Unless I'm missing something, it looks like the ungroup command doesn't
> work on nested group, i.e. one that is owned by another group. The ungroup
> command doesn't return an error either.
> It feels like the only way to do this is to ungroup all the owning groups
> first but that seems fraught with dangers of losing the group structures.
> Is there a better way to do it. By Script I mean.
> lcSQL Software <http://www.lcsql.com>
More information about the Use-livecode