On Mon, 2003-09-29 at 14:51, liquid wrote:
...
>         def callback(self, widget, data=None):
>                a = "%s" % ((3, 4)[widget.get_active()])
>

add 'global a' to callback():
def callback(self, widget, data=None):
        global a
        a = "%s" % ((3, 4)[widget.get_active()]

However, using global variables is bad style, why don't you make 'a' a
class variable?

HTH,
Igor
_______________________________________________
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to