on 04-09-2008 10:39 AM
Hi ,
Can anybody please help me to put row counter for table in Sap WebDynpro for java .
I need to put a row counter in bottom of the table. which shows no. of rows and current row no etc.,
Can any body plz help me.
Thanks and Regards,
Shashi.
Hi,
set the property footerVisible of table to true
Regards
Ayyapparaj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Put a TextView under the table, bind its "text" property to a calculated context attribute "tableInfo" of type "string".
Implement getter like
String getTableInfo(...)
{
int nRows = wdContext.node<TableDataSource>().size();
int selectedRowIndex = wdContext.node<TableDataSource>().getLeadSelection();
return nRows + " rows" + (selectedRowIndex != -1 ? ", selected row: " + selectedRowIndex : "");
}
Armin
Hi Sashi,
In 7.0.x versions we can see in the table footer the number of rows automatically.
If you want to get no. rows and selected row do like this:
int size = wdContext.node<tablenode>().size();
int selectedRow= wdContext.node<tablenode>().getLeadselection()+1;
you can set these values to context and display them
regards,
Siva
footerVisible = true
Armin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.