cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Derek Hohls" <DHo...@csir.co.za>
Subject Re: [CForms] How to set multivalue widget's values ?
Date Mon, 21 Jun 2004 06:13:44 GMT
And maybe the same person knows how to
*get* the values from the CForm multivalue widget
and display them using a JXTemplate loop??

A sample showing both of these would be *very*
helpful and (IMO) needs to be  a part of the
Cocoon forms samples.

Thanks
Derek

>>> jc.textor@gmx.de 2004/06/20 09:25:06 PM >>>
Hi all,

I'm going nuts trying to set values in a CForm multivalue widget.

I obtained the Form model with:

var model = form.getModel();

Then I tried to set the values like this:

model.rubriken = Array(size);
for( i = 0 ; i < size; i++)
    model.rubriken[i] = new java.lang.Integer(val[i]);

When size=0, everything is fine. Otherwise, I get

Cannot set value of field "rubriken" with an object of type 
org.mozilla.javascript.UniqueTag

When I omit the array declaration, I get null pointer exceptions.

Has anybody done this and can explain me how ?

TIA, Johannes

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org 
For additional commands, e-mail: users-help@cocoon.apache.org 


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
MailScanner thanks transtec Computers for their support.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message