Skip to main content

Enabling multiple selection on <af:table>

A common mistake while enabling multiple selection for a data bound table is to leave the default values for attributes(generated while creating the table in a single selection mode) selectedRowKeys and selectionListener as is. This is wrong, these parameters will override the multiple selection that user makes. So you may need to remove them.

To enable multiple select capabilities on a <af:table>,
1. Set rowSelection="multiple"
2. Remove selectedRowKeys and selectionListener attributes(if any)

This is well documented in Fusion Developer's Guide for Oracle Application Development Framework. Please see Section 23.5, "Providing Multiselect Capabilities"

Comments

Suresh said…
hey thanks a bunch! your post was very helpful in an issue i was wokring on..
Jobinesh said…
Glad to be of help :)
Naeem Qasim said…
hi Jobinesh I am Naeem I am facing a problem of displaying values stored in database table in different forms like I have a table employees where I made three attributes (emp_id, name, displayhint)
and data in the table is
1 naeem checkbox
2 qasim radiobutton
3 rao input text
Now i want to display these employees according to the value which i set in displayhint attribute
please help me to solve this problem this is sample data
Preeti said…
Any one has idea to generate id dynamically in forEach loop?

Thanks a lot from advance

Popular posts from this blog

Happy New Year 2018 !

We can't go back and change the beginning, but we always can start where we are and change the ending. Believe in yourself and you will be unstoppable!

Wishing you and your family a very happy new year 2018 !!!

How to set Bind Variable Values at runtime ?

In this post I'm sharing a couple of approaches for programmatically setting bind variables values at run time. This post is an attempt to explain 'When to use what ?'[ In case if you are familiar with 'Bind Variables' in ADF BC, please refer Section 5.10, Working with Bind Variables in Fusion Developer's Guide ]

1. Set the Bind Variable value using RowSet::setNamedWhereClauseParam(...)

You can use use the setNamedWhereClauseParam(...) method on the ViewObject interface (which extends oracle.jbo.RowSet) to set the value for bind variables. Please note this sets the value on default RowSet. In other words, this doesn't have any effect on the secondary RowSets that you/system generates.
ViewObject vo = am.findViewObject("EmployeesView1"); vo.setNamedWhereClauseParam("bindVarDeptId", new Number(10)); vo.executeQuery();
2. Set the Bind Variable value using ViewObject's VariableValueManager::setVariableValue(...)

VariableValueManager Ma…