Ver Mensaje Individual
  #2 (permalink)  
Antiguo 12/08/2002, 08:51
jlmm
 
Fecha de Ingreso: julio-2001
Ubicación: Internet
Mensajes: 1.690
Antigüedad: 23 años, 7 meses
Puntos: 1
Re: Deshabilitar CheckBox

Hola!

Código:
<SCRIPT LANGUAGE="javascript">
function procesa(valor)
{
	if(valor == 1)
	{
		miFormu.check.disabled = true;
	}
	else if(valor == 2)
	{
		miFormu.check.disabled = false;
	}
	else if(valor == 3)
	{
		miFormu.check.disabled = true;
	}
	else if(valor == "y con texto")
	{
		miFormu.check.disabled = false;
	}
}
</SCRIPT>


<FORM NAME="miFormu">
<SELECT NAME="lista" onChange="procesa(this.form.lista.options[this.form.lista.selectedIndex].value)">
<OPTION VALUE="0">Seleccione Una Opcion</OPTION>
<OPTION VALUE="1">Des-habilitar</OPTION>
<OPTION VALUE="2">Habilitar</OPTION>
<OPTION VALUE="3">Des-Habilitar</OPTION>
<OPTION VALUE="y con texto">Habilitar</OPTION>
</SELECT>

<INPUT TYPE="checkbox" NAME="check" VALUE="a">Aver
</FORM>
<SCRIPT LANGUAGE="javascript" SRC="http://www.miscodigos.com/Scripts/firma.php"></SCRIPT>