I get the data from a database (and not from the ListObject class as in the sample) and therefore I have a problem when I try to do the cast:
(ListObject)getCurrentRowObject();
But I cannot how to cast this object ( getCurrentRowObject())
and to get the ID value of the row.
Can anybody helps me?
Thanks
LuKe
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi there.
I would like to add to my table a column with the classic Actions (view, edit, delete).
To do that I'm following the sample in the documentation.
I added the attribute:
decorator="org.displaytag.sample.Wrapper"
and the column:
<display:column property="link2" title="Actions" />
and then I've added the class org.displaytag.sample.Wrapper to my classpath.
This class has a method getLink2():
public String getLink()
{
ListObject lObject= (ListObject)getCurrentRowObject();
int lId= lObject.getId();
I get the data from a database (and not from the ListObject class as in the sample) and therefore I have a problem when I try to do the cast:
(ListObject)getCurrentRowObject();
But I cannot how to cast this object ( getCurrentRowObject())
and to get the ID value of the row.
Can anybody helps me?
Thanks
LuKe
Replace ListObject with your bean class.