[Migrated content. Thread originally posted on 08 February 2012]
I have a web page with gridview. I want to be able to click on any line in the grid, and do some processing on the selected line. How do I do it? I've created a method (shown below), and "onmouseover" etc work, but how do I call a method, or do anything, when a line is clicked on.Any advice gratefully recieved. Many thanks in advance.
method-id grdSearch_RowCreated public.
***************************************
local-storage section.
procedure division.
invoke grdSearch::Attributes::Add("title", "Click to select"). *> WORKS
invoke grdSearch::Attributes::Add"onmouseover", "this.style.cursor='pointer';this.style.color='white';"). *>WORKS
invoke grdSearch::Attributes::Add("onmouseout", "this.style.color='blue';this.style.background='white';"). *>WORKS
invoke grdSearch::Attributes::Add("onclick", "invoke self::grdSearch_SelectedIndexChanged()"). *> DOES NOTHING
goback.
end method.