0

I have an application developed in javascript and adopted in SAP (BSP).

After system copy ENTER button is not working in system - when I change the data it is endless looping the loading.

code fragment for enter function:

function Enter(keycode) {
if (window.event.srcElement.type == "textarea" && keycode == 13 ) {
glLastKeycode = keycode;
keycode = 0;
} else {
glLastKeycode = keycode;
}
if (keycode == 13) {
write_wait();
window.external.AutoCompleteSaveForm(document.forms[0]);
document.forms[0].elements['event'].value='SPEICHERN';
document.forms[0].submit();

the picture how it is processing in app:

  1. change quantity
  2. ENTER button press image description
Sandra Rossi
  • 11,934
  • 5
  • 22
  • 48
  • What are the first and last statement of the endless loop? (Does it reach the statement after `document.forms[0].submit()` or is it this statement which executes the `Enter` function again? Then, how is the `Enter` function linked to an event?) How is this Javascript question related to SAP software? – Sandra Rossi Jun 09 '21 at 06:12
  • 1) it is the statement which executes the function ENTER. 2) External application , SAP BSP element is developed in javascript. P.S. I can not get why loading process is just endless. I can not see and catch any inconsistency in fragment. I have tested different ways, nothing helps. – Stanislav Jun 10 '21 at 08:00

0 Answers0