Hello,

I have the following Table in my html file



<table border="2" width="100%">

     <tr t:type="loop" source="products" value="currentProduct">

<td> <a t:id="select" t:type="actionlink" context="currentProduct"> ${currentProduct.id}</a></td>

           <td>${currentProduct.id}</td>

           <td>${currentProduct.name}</td>

           <td>${currentProduct.description}</td>

     </tr>

</table>



in my Java file i have all required data/Getters/Setters and I can disply the data.

I hava a method in my java file like this:



@OnEvent(component = "select")

String whenUserClicks( Product currentProduct)

{

     System.out.println("ok");

     return null;

}





I get an execption, which I know what does it mean.

Exception in method org.apache.tapestry.tutorial.pages.Start.onActionFromCurrentProduct(org.apache.tapestry.tutorial.others.Product) (at Start.java:84), parameter #1: Could not find a coercion from type java.lang.String to type org.apache.tapestry.tutorial.others.Product.



My question is: how should my method or my HTML looks like to be able to receive the Product object and not an integer.

It is possible, isnt it?

Thanks in advance

John


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

Reply via email to