I want In Custom input Window if the user pressed the ENTER key, a predefined button clicked.
it’s achievable by JS code, and its working in IE, but no luck in Custom input window.
is there any solution to my problem?
// Number 13 is the “Enter” key on the keyboard
if (event.keyCode === 13) {
// Cancel the default action, if needed
event.preventDefault();
// Trigger the button element with a click
document.getElementById(“the button id, which is usually ok or accept buttonn*”).click();
}
});