Skip to Main Content

Oracle Forms

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!

forms javascript communication

Walid KHARRATApr 16 2019 — edited Apr 16 2019

Hi,

i want to achieve forms js communication (html menu). So when user click i pass the name of the link form. This code work fine in ie :

var x = document.getElementById("testjs");

var y = x.contentWindow.document;

y.forms_frame.raiseEvent('call_form',form.nom.toLowerCase());}

this work fine with IE11 but i want to use it with firefox esr 52.9 and google chrome 43. Both support applet

i add this function(found in the net)  to my js like this:

function raiseEvent(element, eventName, eventDetails) {

        var event;

        var bubbles = true;

        var cancelable = false;

        try {

            event = new CustomEvent(eventName, {

                bubbles: bubbles,

                cancelable: cancelable,

                detail: eventDetails

            });

        } catch (e) {

            event = document.createEvent("CustomEvent");

            event.initCustomEvent(eventName, bubbles, cancelable, eventDetails);

        }

        element.dispatchEvent(event);

    }

so my code becomes:

raiseEvent(y.forms_frame,'call_form',form.nom.toLowerCase());

in firefox or ie theres no error in javascript console but nothing happen.

how can i dispatch the event like with the IE raiseEvent.

regards

Walid

Comments

Post Details

Added on Apr 16 2019
1 comment
149 views