How to gray out/disable all widgets within a sizer

In a program that I am working on, I use a RadioBox to
determine where to obtain values for use. I want to
allow the user to create a text file which the program
can import and process or to input commands using the
widgets in a sizer below. I haven't found much on
graying out widgets in general or more specifically
graying out a group of widgets. The specific widgets I
need to gray out are a label, a listbox, and a
textctrl. Is there some standard way of doing this, or
do I have to destroy the widgets and recreate them when
the radio buttons indicate that I should?

--vicki

What about putting the sizer in question inside a panel (say
self.panel1) and make each widget a child of the panel? Then:

    for widget in self.panel1.GetChildren():
        widget.Enable(False)

or

    for widget in self.panel1.GetChildren():
        widget.Enable(True)

Regards,

ยทยทยท

--- vicki@stanfield.net wrote:

In a program that I am working on, I use a RadioBox to
determine where to obtain values for use. I want to
allow the user to create a text file which the program
can import and process or to input commands using the
widgets in a sizer below. I haven't found much on
graying out widgets in general or more specifically
graying out a group of widgets. The specific widgets I
need to gray out are a label, a listbox, and a
textctrl. Is there some standard way of doing this, or
do I have to destroy the widgets and recreate them when
the radio buttons indicate that I should?

=====
Donnal Walter
Arkansas Children's Hospital