Removing everything in parent group

I have a parent group that holds smaller child groups. In turn these groups hold a child image and piece of text. How do I remove everything found within that master parent group? I can provide some code if asked.

-- 1. Just remove the master group:masterGroup:removeSelf() masterGroup = nil -- OR -- 2. If you need to keep the master group: while( masterGroup.numChildren \> 0 ) do    masterGroup[1]:removeSelf() end  

As it turns out that wasn’t my problem. The display object is nested, and when clicked event.target returns the display group instead of the object. I need to check a value that I put on the display object. Since it is returning the group though, I’m getting nil.

Is there a work around? Am I even making sense?

huh, not really getting it.
event.target is giving you the object you assign the event listener too, so if you want your object to be the target just assign the listener to the object instead of the group.

maybe you could describe what you would like to do at all?
your last post is more confusing than describing the actual problem.

-- 1. Just remove the master group:masterGroup:removeSelf() masterGroup = nil -- OR -- 2. If you need to keep the master group: while( masterGroup.numChildren \> 0 ) do    masterGroup[1]:removeSelf() end  

As it turns out that wasn’t my problem. The display object is nested, and when clicked event.target returns the display group instead of the object. I need to check a value that I put on the display object. Since it is returning the group though, I’m getting nil.

Is there a work around? Am I even making sense?

huh, not really getting it.
event.target is giving you the object you assign the event listener too, so if you want your object to be the target just assign the listener to the object instead of the group.

maybe you could describe what you would like to do at all?
your last post is more confusing than describing the actual problem.