Re: [Boa Constr] Can I use an array (or list) to contain multiple widgets
Status: Beta
Brought to you by:
riaan
From: Riaan B. <riaan@e.co.za> - 2006-07-28 05:02:34
|
Hi Marc, Marc Shapiro wrote: > I'm still trying to find a way to do this. Is it possible? This would > make it possible to access a list of widget objects in a 'for', or > 'while' loop, instead of accessing each one individually, by its unique > name. > > Marc Shapiro wrote: > > >>Is there any way, using Boa Constructor, to have multiple controls (say >>8 sliders) set up as a single array (or list) of 8 sliders as opposed to >>using 8 individual variable names for them? No there is no way to do that with the Designer. Just define your slider array in your own code after the call to _init_ctrls(). e.g. self.sliders = [self.slider1, self.slider2, self.slider3] Cheers, Riaan. |