with something that can dynamically change the defaults on every invocation. I'll
keep trying.
Thanks again,
Nicky
On 7/9/06, Ed Singleton <[EMAIL PROTECTED]> wrote:
I think you would do:
def getDefault(list):
if list = "numbers":
return "three"
#etc
then in your fields use a the callable to get your default value.
numbers = widgets.SingleSelectField ("Numbers",
options=opt_num, default=getDefault("numbers"))
letters = widgets.MultipleSelectField("Letters", options=
opt_let, default=getDefault("letters"))
but I'm not sure whether it calls the callable every time the form is
displayed. If it does this will work fine.
Ed
--
--
Nicky Ayoub
G-Mail Account
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---

