Scroll to specific row in a table on pageload


Following code will help you to scroll to a specific row in a af:table on page load.

//Code to scroll to a specific row
this.tableBinding.setRowIndex(rowIndex);
RowKeySet ps = this.tableBinding.getSelectedRowKeys();
ps.clear();
ps.add(this.tableBinding.getRowKey());
AdfFacesContext.getCurrentInstance().addPartialTarget(this.tableBinding);

Also set the displayRow=selected for the table

2 thoughts on “Scroll to specific row in a table on pageload

  1. Duminda

    Hi, When I uptook this jar file, I get this error on seahcringCaused by: oracle.jbo.JboException: JBO-29000: Unexpected exception caught: oracle.mds.exception.MDSRuntimeException, msg=MDS-01201: An invalid parameter cannot be used when constructing a query condition.Is there anything that I have to do, to get the search performed as expected?-Arvind

    Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s