Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to disable datascroller in jsf when the datatable doesn't have any records

 
S.Reddisekhar Reddy
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how to disable datascroller in jsf when the datatable doesn't have any records
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18020
47
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That depends partly on what you are using for a datascroller. There is no datascroller UI component in the core JSF. To get one, you have to either design/code/debug/maintain one of your own or use a third-party JSF extension tagset such as Tomahawk or RichFaces.

It also depends on how you define "disable". Whether you want the scroll gadget literally disabled (visible ghosted) or not displayed (rendered) at all.

However, one thing that you can rely on almost universally is that as long as your target dataTable has a statically-determined sized (something like a ListDataModel as opposed to a JDBC datamodel), then the following EL construct should work:


You can also use the "empty" EL expression to hide empty tables and/or display "No Data Available" messages.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic