Advertisement
LordKusa

Calculadora

Aug 1st, 2018
203
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var valor
  2.            
  3.             function CommandClick1(){
  4.                 valor = document.getElementById("1").value;
  5.                 document.getElementById("nombre").value += valor;
  6.             }
  7.             function CommandClick2(){
  8.                 valor = document.getElementById("2").value;
  9.                 document.getElementById("nombre").value += valor;
  10.             }
  11.             function CommandClick3(){
  12.                 valor = document.getElementById("3").value;
  13.                 document.getElementById("nombre").value += valor;
  14.             }
  15.             function CommandClick4(){
  16.                 valor = document.getElementById("4").value;
  17.                 document.getElementById("nombre").value += valor;
  18.             }
  19.             function CommandClick5(){
  20.                 valor = document.getElementById("5").value;
  21.                 document.getElementById("nombre").value += valor;
  22.             }
  23.             function CommandClick6(){
  24.                 valor = document.getElementById("6").value;
  25.                 document.getElementById("nombre").value += valor;
  26.             }
  27.             function CommandClick7(){
  28.                 valor = document.getElementById("7").value;
  29.                 document.getElementById("nombre").value += valor;
  30.             }
  31.             function CommandClick8(){
  32.                 valor = document.getElementById("8").value;
  33.                 document.getElementById("nombre").value += valor;
  34.             }
  35.             function CommandClick9(){
  36.                 valor = document.getElementById("9").value;
  37.                 document.getElementById("nombre").value += valor;
  38.             }
  39.             function CommandClick10(){
  40.                 valor = document.getElementById("0").value;
  41.                 document.getElementById("nombre").value += valor;
  42.             }
  43.             function CommandClick11(){
  44.                 valor = document.getElementById(",").value;
  45.                 document.getElementById("nombre").value += valor;
  46.             }
  47.             function CommandClick12(){
  48.                 valor = document.getElementById("=").value;
  49.                 document.getElementById("nombre").value += valor;
  50.             }
  51.             function CommandClick13(){
  52.                 valor = document.getElementById("%").value;
  53.                 document.getElementById("nombre").value += valor;
  54.             }
  55.             function CommandClick14(){
  56.                 valor = document.getElementById("x").value;
  57.                 document.getElementById("nombre").value += valor;
  58.             }
  59.             function CommandClick15(){
  60.                 valor = document.getElementById("-").value;
  61.                 document.getElementById("nombre").value += valor;
  62.             }
  63.             function CommandClick16(){
  64.                 valor = document.getElementById("+").value;
  65.                 document.getElementById("nombre").value += valor;
  66.             }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement