cancel
Showing results for 
Search instead for 
Did you mean: 

Set Foocus on a particular celll in a table view

Former Member
0 Kudos

Hi ,

I have a table view , When i select a row in the table view , focus must be set on the first column, the first column is a editable column .

I have used <phtmlb:focusRect>

the attribute for the focusElementId is the cell id of the particular cell where focus is to be set..

but the focus is not set ...

when I give the id of the table view .. it gets focus on the table view ..

for eg., table view id = 'itmlst' when i pass this as attriute it gets focus on the table view ..

when i try to get focus on a particular cell .. id 'itmlst_1_1' .. it doesnt get focus on that cell ..

Please give me ur suggestions for setting the focus on a particular cell when selecting a row

Accepted Solutions (0)

Answers (1)

Answers (1)

athavanraja
Active Contributor
0 Kudos

to set focus you can do it thru javascript.

<SCRIPT LANGUAGE="JScript">

function textFocus(elementid)

{

var element = document.getElementsByName(elementid);

element.select();

}

</SCRIPT>

sorround this javascript by a abap if else condition and pass the elementid with a abap variable.

Regards

Raja