You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Tony Edwards <TE...@civica.com.au> on 2005/01/13 03:52:08 UTC

Multivalue field - setting values

Hello All,
I'm trying to set the values of a multivalue listbox from flow and I 'm 
having a few issues.
I've  read a few entries in various blogs and Wiki pages but I just 
can't seem to get the thing to fly.

Reading multiple values set in the control is a snack:

        for(var i = 0; i < model.permissions.length; i++){
            print("Permission value " + i + " = " + model.permissions[i]);
            lRoleNum += model.permissions[i];
        }

But when I go to do the reverse of this I get the list of values 
displayed but no selected values:
    var testValues = Array();
    for(var i=0; i<4; i++ ){   
        testValues[i] = new java.lang.Long(i);
    }
    model.permissions = testValues;   

What am I doing wrong?!??
Any help gratefully appreciated!

Regards
Tony

--------------------------------------------------------------------- 
This email is from Civica Pty Limited and it, together with any attachments,
is confidential to the intended recipient(s) and the contents may be legally
privileged or contain proprietary and private information. It is intended
solely for the person to whom it is addressed. If you are not an intended
recipient, you may not review, copy or distribute this email. If received in
error, please notify the sender and delete the message from your system
immediately. 
Any views or opinions expressed in this email and any files transmitted with
it are those of the author only and may not necessarily reflect the views of
Civica and do not create any legally binding rights or obligations
whatsoever. Unless otherwise pre-agreed by exchange of hard copy documents
signed by duly authorised representatives, contracts may not be concluded on
behalf of Civica by email. 
Please note that neither Civica nor the sender accepts any responsibility
for any viruses and it is your responsibility to scan the email and the
attachments (if any). All email received and sent by Civica may be monitored
to protect the business interests of Civica. 
---------------------------------------------------------------------