File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSF and the fly likes h:datatable, how multiply row cell A with row cell B and set value in row cell C Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "h:datatable, how multiply row cell A with row cell B and set value in row cell C" Watch "h:datatable, how multiply row cell A with row cell B and set value in row cell C" New topic
Author

h:datatable, how multiply row cell A with row cell B and set value in row cell C

Milutin Markovic
Greenhorn

Joined: Mar 18, 2010
Posts: 12


I know how to multiply that in backing bean and show in third cell. Bat what is interesting me how can multiply two cell on client side in jsf page. Thanks for any halp.
Greg Charles
Sheriff

Joined: Oct 01, 2001
Posts: 2771
    
  10

I believe EL (expression language) supports basic arithmetic, so what you'd do is: #{item.price * item.quantity}

Otherwise, you can always add another getter to item's class that returns the extended value.
Milutin Markovic
Greenhorn

Joined: Mar 18, 2010
Posts: 12
Thanks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: h:datatable, how multiply row cell A with row cell B and set value in row cell C
 
Similar Threads
Fixed header scroll bar to datatable
Using of nested Datatables
how to select a row datatable
JSF java.util. Concurrent ModificationException
datatable - row colors