Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Refresh the component using javascript in ADF

adrinaSep 17 2016 — edited Sep 17 2016

Hi,

Am using jdeveloper 11.1.1.7.0

I have dragged and dropped my StoreView as adf tree table.

I have written a javascript to perform the key board navigation.

i need to refresh the component once the kyeboard navigation performs, i tried using autoSubmit and partial trigger but it doesnt work,

Below is the javascript which i used for keyboard navigation

function detectKey(evt) {

        var inputText = evt.getSource();

        var id = inputText.getClientId();

      

        var lastcolen = id.lastIndexOf(":");

        var beforeInputId = id.substring(0, lastcolen);

     

        var penultimateColen = beforeInputId.lastIndexOf(":");

        var rowNum = parseInt(beforeInputId.substring(penultimateColen+1, beforeInputId.length));

      

        var inputId = id.substring(lastcolen+1, id.length);

     

        var beforeRowNum = id.substring(0, penultimateColen);

        var colen = ":";

     

//        var start2 = id.indexOf(":") + 1;

//          var end2 =  id.lastIndexOf(":");// var numValue =

//        parseInt(id.substring(start2, end2));

//        alert(id.substring(start2, end2));

        var arrows = evt.getKeyCode();

        switch (arrows) {

            // Up       arrow

            case 38:

            rowNum = rowNum - 1;

            break;

           

            //      Down     arrow

            case 40:

            rowNum = rowNum + 1;

            break;

        }

        var newStr = beforeRowNum + colen + rowNum + colen + inputId;

      

        var comp = AdfPage.PAGE.findComponentByAbsoluteId(newStr);

        if (comp != undefined) {

           comp.focus();

        }

}

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 15 2016
Added on Sep 17 2016
1 comment
741 views