[Zope] Formulator--pre-selecting a line in a multiline field
David Washburn
dwashburn@aminfo.com
Mon, 21 Jul 2003 13:13:36 -0400
Does anyone know how to preset the selected field in a multiline field in a
Forumlator form.
The form is built with Formulator widgets and displayed using DTML - and I
have it working.
I am loading the list in a multiline field from a SQL table -- and I use a
Python script to build the list of tuples needed. That works.
Now I want to use a value from the database record I am displaying to set
the value selected in the list -- before displaying the page. I can't figure
out how to preset the selected field in the list.
If the list looks like
ABC, 1
DEF, 2
HIJ, 3
and in the database the field has a value of 2.
I would like the form, when it is rendered, to have the second line "DEF"
already selected.
I have looked in the documentation and can't find an example of this.
Any suggestions -- this is urgent!
I decided to go with Formulator and now I can't finish implementing several
forms because I can't figure this out.
Thanks,
David
=======================================
David T. Washburn DWashburn@AmInfo.com
Amherst, MA USA
413 256-3103