This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JSF and the fly likes Displaying total Number of columns in Datatable Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Displaying total Number of columns in Datatable" Watch "Displaying total Number of columns in Datatable" New topic
Author

Displaying total Number of columns in Datatable

Abiodun Adisa
Ranch Hand

Joined: Jan 17, 2002
Posts: 495
I am planning on displaying the total number of columns in a Datatable, problem is that datatable is dynamic, it is passed a list that is retrieved from the database

this is the Datatable

<t:dataTable var="category" width="700" id="searchList"
rows="10" value="#{searchResult.jobs}">

the outputText is supposed to retrieve the length of value="#{searchResult.jobs}"> and display it on the same page as the datatable, Please hod do i implement this?
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15961
    
  19

I think you meant number of rows. Since that's not a repeating item, it wouldn't be appropriate to display it in the datatable itself, you'd normally output it in a separate control such as outputText.


Customer surveys are for companies who didn't pay proper attention to begin with.
Abiodun Adisa
Ranch Hand

Joined: Jan 17, 2002
Posts: 495
Originally posted by Tim Holloway:
I think you meant number of rows. Since that's not a repeating item, it wouldn't be appropriate to display it in the datatable itself, you'd normally output it in a separate control such as outputText.


Yes i meant the number of rows, I have a outputText that would display the number of rows
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Displaying total Number of columns in Datatable
 
Similar Threads
datatable renders empty rows
Problem with building columns dynamically using dataTable tag
Presenting variable number of columns with primefaces datatable
Problem with h:datatable
JSF datatable doubt