How to delete all child components from Panel?
-
I'm looking to remove all child components from a parent panel but found only
ScriptPanel.removeFromParent()
in the HISE documentation.
Does anyone know a way to achieve this?
Any help would be greatly appreciated. Thanks! -
for (x in panel.getChildPanelList()) x.removeFromParent();
-
@d-healey It doesn't work on my end
HiseSnippet 782.3ocsVssaSCCF1tsAVKLDShGfncUqzzT6XbPZBQY8.ph0sJxXZb0jWhai0Rribb1VAgDOZ7Hwa.76jzFWVGGpX9hp9e3y9y+mbFIEtz3XgDgqd7zHJB+PKmobkeGeBiiFzUqHhvoAmonwJz9SiHwwTODFW9sZOvUqfRWe+06SBHbWZgJD5DAykd.KjoJzNp86XAA8IdziYgFdua6AtBdGQfHAXSYqlnHh6EjIzCIZ2JYgv2qmGSIjNJBPFDtx9BuoN9hq3Y9eBKlcd.UKzB4.aTl59h.OMi0ZQc7YAdilcqiQvtLpHFTNKF7DqgLO1b8EwhGmZvt.gY7.WZQ5UdA50xjdMMn2RnD1fRUxnzFVNtRVjpvhlOOvZ.WQkiIPX2jJY9hJsK1pi.7fq1NjbAsuDDlin9ya1bKa3mF6UCh7wJ6KIR6Q5jcK6WYOC3DppiHLRvAg5alYdS.RswBoc8qsY7bLodldWzhGvhU0aznlMrtdaIMTbo97CGQj5MpwdiS3tJlfaK3GJTzi30aT6y0pV6K0r+USiGuTaZFJEAAT4RMqKuj+Nf04IgmSkaA26fD5bGgX9hIRqaOQZVm4lEvLbTvGvYpihn7aq5CkGkg+8gAcIJhN6mqC7KhJULMEvcoWBsRY0BUs5RiuPIhR8MO0.zTkZc8YUJ5r.hA0CqYkkfPWOua6q71SmK7sSaetP5QkNrOQM6nwkL196eaa+iL0XdHvZpovULOkeghO11mxl3qL0DkVcXbpy4N5elJ6bmQka1dBCFDdIAD0hSKziHyM.UdKzhpaC4wL0zEC3+mFg72RwMrFwTt9KmikVBGg5y6BNlO3ccqdiGScUEDrhU+SualxhduHQw3SFRTRFToXcXRnC71iKENcNjn0c93R5dzL4lZYcDvgx8RE9ArxM1RKiyM1ZlQTHwUJNyMadidz9ZoZ.NwSeUqp0PsrcKT5LHy3bH7RyYttKtU2.3NqJvmtp.2cUA9rUE3yWUfuXUA9x+LP8GB7lDkHLqsAgFNpW5.bLtGm.UfoUqneBjq+GRL
-
It won't do anything. -
@sakorada Those aren't child panels. You can't remove those at run time.
Child panels are created using
panel.addChildPanel()
-
@d-healey Ahhh , i see
Thank you