Tema: dROPDOWNlIST
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 15/04/2012, 17:50
jasamestica
 
Fecha de Ingreso: marzo-2006
Mensajes: 329
Antigüedad: 18 años, 1 mes
Puntos: 1
dROPDOWNlIST

en un control web dropdownlist quiero cambiar con javascript la propiedad visible si el indice seleccionado es 1 2 o 3, pero no funciona con la siguinte sintaxis


drpBuscarPor.Attributes.Add("onchange", "if(document.getElementById('" + txtBusqueda.ClientID + "').selectedIndex==1 || document.getElementById('" + txtBusqueda.ClientID + "').selectedIndex==2 || document.getElementById('" + txtBusqueda.ClientID + "').selectedIndex==3){ document.getElementById('" + txtBusqueda.ClientID + "').style.visibility='visible';}");