[wxPython-users] combobox change style

Robin Dunn robin at alldunn.com
Thu Nov 2 20:41:22 PST 2006


Thomas Thomas wrote:
> Hi All,
>  
> Can I swicth between wx.CB_SIMPLE and no style for a combobox, I want 
> this done on a button click event based on whether combobox has dropdown 
> values it or not.
>  
>  
> I tried using SetWindowStyle and Refershing the control..But that didnt work

Most styles can't be changed after the control has been created, as the 
styles equate to a flag that is passed to the native widget creation 
function.  You'll need to create a new control and destroy the old one.

-- 
Robin Dunn
Software Craftsman
http://wxPython.org  Java give you jitters?  Relax with wxPython!





More information about the wxpython-users mailing list