Hi,
Can this be added in the doc
http://cocoon.apache.org/2.1/userdocs/forms/binding.html

Or a pointer given to http://cocoon.apache.org/2.1/apidocs/ in the
documentation.
Stating the information for Multi value files can be found in the api
docs.

I am sure it would help many people like me.

Regards,
Moin

-----Original Message-----
From: Moinuddin Ahmed (WT01 - CORPORATE) 
Sent: Saturday, May 29, 2004 4:08 PM
To: [EMAIL PROTECTED]
Subject: RE: Cocoon binding for multivaluefield (multi select combo box)


Thanks Bruno.

That did it.
Have a nice weekend.
Regards,
Moin

-----Original Message-----
From: Bruno Dumon [mailto:[EMAIL PROTECTED] 
Sent: Saturday, May 29, 2004 3:56 PM
To: [EMAIL PROTECTED]
Subject: Re: Cocoon binding for multivaluefield (multi select combo box)


On Sat, 2004-05-29 at 12:10, [EMAIL PROTECTED] wrote:
>  
> Hi ,
>  
> I am trying to read values from a multivaluefield (multi select combo
> box) from a cocoon form and use cocoon form binding to extract the
> values. My intent is to create an xml file from the data that has been
> selected in the form.
>  
> I have tried all variation of cocoon form binding to get the data ,
> but not able to do so.
>  
> I am able to successfully read the value of a single select drop down
> box, by using " <value id="searchFields" path="@searchFields" />" , 
> but not able to get values for multi select combo box. I  have tried 
> the following:
>  
> 1. ) I have tried using repeaters but that give a class cast
> exception. at form.save method <?xml version="1.0" encoding="utf-8"?>
>  
> <context path="/content"
> xmlns="http://apache.org/cocoon/forms/1.0#binding";>
>   <repeater id="searchFields" parent-path="." row-path="searchFields">
>    <identity>
>         <value id="name" path="@id" />
>       </identity>
>       <on-bind>
>         <value id="name" path="@id" />
>       </on-bind>
>       <on-insert-row>
>         <insert-node>
>           <entry name="" />
>         </insert-node>
>       </on-insert-row>
>     </repeater>
> </context>
> 
>
========================================================================
> 2. ) later I tried using only   <value id="searchFields"
> path="@searchFields" />, with this I am not getting any exceptions as
> such but I am not able to get the values of the selected combo box.
>  
> ======================================================================
> ==
> 3)
> I also tried using aggregator, with this I am not getting any 
> exceptions as such but I am not able to get the values of the selected

> combo box. <aggregate id="searchFields" parent-path="." 
> row-path="searchFields">
>    <value id="value" path="@value" />
>    </aggregate>
>
========================================================================

>  
> My definition file is as below:
> <multivaluefield id="searchFields">
>       <datatype base="string" />
>       <selection-list src="cocoon:/select-search-fields"
> dynamic="true" />
>     </multivaluefield>>
>  
>  
>  
> Can any one please throw some pointers what I can do to get the value
> from a multivaluefield or let me know where I am going wrong

I thought there was a multivaluefield binding... yes, there is: check
the javadoc of the class MultiValueJXPathBindingBuilder for more info.

BTW, if the default bindings don't suffice, it is always possible to
write some custom code (eg. using the fb:javascript binding) to do the
binding for you.

-- 
Bruno Dumon                             http://outerthought.org/
Outerthought - Open Source, Java & XML Competence Support Center
[EMAIL PROTECTED]                          [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to