navya kodali
Posts: 0
Joined: Wed Jan 22, 2014 6:47 am

which event has to call?

i have some number of input fields.
when i am adding 1+2 result is placed on 3 filed by calling keyup event of 2
4+5 result is placed on 6 filed by calling keyup event of 5
i want total of 3+6 in 7 input filed.for that which event has to call?
value change is not working?
when put cursor on 7 only it works.
but i want when 3,7 input value changed then i want result in total filed how to do this?

Nikita
Posts: 0
Joined: Fri Feb 28, 2014 4:02 pm

which event has to call?

Hello,

You can add such a function:

function fillInput7(){
var input3= Appery("input3").val();
var input6= Appery("input6").val();
if ((input3 !="") &&(input6 !="")){
Appery("input7").val(input3+input6);
}
}
and invoke this function on an event, when you recalculate input3 and input6.

navya kodali
Posts: 0
Joined: Wed Jan 22, 2014 6:47 am

which event has to call?

on which event i have to call is my question. i did coding part.
how to call that function in which event?

Nikita
Posts: 0
Joined: Fri Feb 28, 2014 4:02 pm

which event has to call?

You should do it on keyup 2 and 5, when you recalculate values.

navya kodali
Posts: 0
Joined: Wed Jan 22, 2014 6:47 am

which event has to call?

can't we do on value change event in 6 and 7?
how to call fillInput7 function?
"fillInput7();"
is this correct syntax to call function or any other way?

Nikita
Posts: 0
Joined: Fri Feb 28, 2014 4:02 pm

which event has to call?

Hi Navya.

change event triggers when user exit from the input.

keyup event triggers when user pressed key in the field(it more preferable).

Yes. Following code is correct to call the function "fillInput7".

fillInput7();
Regards.

navya kodali
Posts: 0
Joined: Wed Jan 22, 2014 6:47 am

which event has to call?

i wrote this code in screen1 load event.
function display(){
alert("loaded");
}
call this function in input value change event select action runjs and call as "display();"
for checking this wrote an alert.that alert was displayed.but function is not called.
alert("loaded"); message not displayed.
why is there anything wrong?

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

which event has to call?

Hello!

Please check are there any errors in console?

Return to “Issues”