Hello everyone,

We had to develope a little bit complicated request form, and
encountered with some strange behaviors of PickList control. Here is
the deal:
Our request form consists of several PickLists with different
configurations and actions, most of them configured to use 2 lists (via
the "Show 2 lists" attribute), we found it very handy for users who has
to deal with those forms. In general, when initiator selects items he
needs from one of our PickLists, onChange event is fired and script
checks choosen items for specified item, if this item is among them then
script fires another event that enables second PickList.
Here the values of configured attributes of those PickLists:
PL1:
Display Label: PL1
Editable: true
Required: false
Visible: true
Multivalued: true
EventsnLoad, onChange, loadPL1Values
Allow multiple selections: true
Field width in pixels: 200
Number of lines displayed: 3
Show 2 lists: true
Sort entries: true
onLoad: field.fireEvent("loadPL1Values");
onChange: checks selected items for specified one(f.e. looking for
data1) and if found fires showPL2, else fires hidePL2
loadPL1Values: field.setValues(["data1", "data2"],["disp1","disp2"]);

PL2:
Display Label: PL2
Editable: true
Required: false
Visible: true
Multivalued: true
Entity key for DN expression lookup: applicationProcess
EventsnLoad, showPL2, hidePL2, loadPL2Values
Display expression: cN - description
Allow multiple selections: true
Field width in pixels: 200
Number of lines displayed: 5
Show 2 lists: true
Sort entries: true
onLoad: field.fireEvent("loadPL2Values"); field.fireEvent("hidePL2");
showPL2: field.enable(); field.setRequired(true);
hidePL2: field.disable(); field.setRequired(false);
loadPL2Values: loads values using IDVault globalQuery
N.B.: PL2 becomes disabled only after onLoad event fired and not via
Editable attribute.

Set of strange behaviors that applies to IE 6/7: First of all, when PL2
is disabled, browser doesn't limit number of lines displayed, it shows
all the lines loaded, in addition to the fact that it does not show the
second list(since PL2 disabled there is no need in it right now, but
wait...). When initiator selects specified item in PL1, and showPL2
event fires, PL2 becomes enabled, number of lines displayed in it
changes to 4, regardless to the attribute which was set to 5, but still
there is no second list(now it's possible to select with CTRL key
pressed - not too convenient way). If initiator removes the trigger item
from the PL1, PL2 becomes disabled and its number of lines becomes
unlimited again.
After playing a bit with attributes here our conclusion: When PickList
is disabled there is no limit at all for number of lines displayed and
it doesn't depend nor on "Show 2 lists" attribute nor on "Number of
lines displayed" attribute.
Strange behavior that applies to IE 6/7 as well as to FireFox 2.0.0.12:
in the beggining we've tried to hide unnecessary fields but browsers
refused to show fields with "Show 2 lists" set 'true' after hidding.

We're not sure whether those features by design or not, known bugs or
not, but we will be thankful for any advices or workarounds.


--
vladib
------------------------------------------------------------------------
vladib's Profile: http://forums.novell.com/member.php?userid=10607
View this thread: http://forums.novell.com/showthread.php?t=358506