Returning a value from a Tk dialog

2005-11-07 Thread Gordon Airporte
The dialogs in tkColorChooser, tkFileDialog, etc. return useful values from their creation somehow, so I can do stuff like this: filename = tkFileDialog.askopenfilename( master=self ) I would like to make a Yes/No/Cancel dialog that can be used the same way (returning 1/0/-1), but I just cannot

Re: Returning a value from a Tk dialog

2005-11-07 Thread Ron Adam
Gordon Airporte wrote: > The dialogs in tkColorChooser, tkFileDialog, etc. return useful values > from their creation somehow, so I can do stuff like this: > > filename = tkFileDialog.askopenfilename( master=self ) > > I would like to make a Yes/No/Cancel dialog that can be used the same > wa

Re: Returning a value from a Tk dialog

2005-11-07 Thread Fredrik Lundh
Gordon Airporte wrote: > The dialogs in tkColorChooser, tkFileDialog, etc. return useful values > from their creation somehow, so I can do stuff like this: > > filename = tkFileDialog.askopenfilename( master=self ) > > I would like to make a Yes/No/Cancel dialog that can be used the same > way (re