You need to sign in to do that
Don't have an account?
Scott.M
onRowClick of pageBlockTable Best Practice
Hi,
I'm trying to use the onRowClick of the pageBlockTable to update a section of a page with javascript based on which row was clicked. How can I determine which row has been clicked on the onRowClick event and grab the id of the object in that row?
Thanks for any help :)
I'm trying to use the onRowClick of the pageBlockTable to update a section of a page with javascript based on which row was clicked. How can I determine which row has been clicked on the onRowClick event and grab the id of the object in that row?
Thanks for any help :)
Thanks again for any help :)
Message Edited by Scott.M on 08-12-2008 06:42 AM
I refer your code and it works for me to get name and id on clicking the row.
Below is the sample code, that i used.
<apex:pageBlockTable value="{!incidents}" var="Inc" id="tbl_id" border="1" onRowClick="Test('{!Inc.name}','{!Inc.Id}')">
and in the javascript ,
function Test(name,id)
{
alert("Name of the record is"+ name + "and the record id is " +id);
}
Thanks,
SAKTI