Ver Mensaje Individual
  #2 (permalink)  
Antiguo 19/02/2004, 18:48
4ndr01d3
 
Fecha de Ingreso: junio-2002
Mensajes: 14
Antigüedad: 22 años, 8 meses
Puntos: 0
Despues de buscar encontre la solucion, asi que si a alguien le interesa, la funcion que hice fue(parezco loco hablando solo, yo pregunto yo contesto):

function verificar()
{
try
{
var lista = document.formu.bebidas;
var eachGroup = lista.firstChild;

var length = lista.length + lista.childNodes.length;
var eachOption=eachGroup.firstChild;
var sele=0;
for (var i=0;i<length;i++) {
if (eachOption!=null){

if (eachOption.selected){
sele++;
//alert("Del grupo "+eachGroup.label+" han sido seleccionados "+sele+" items"+i);
}
if (sele>1){
alert ("NO pueden seleccionarse 2 opciones de un mismo grupo("+eachGroup.label+") en el campo descripcion");
return;
}

eachOption=eachOption.nextSibling;
}else{
sele=0;
if (i+1!=length){
eachGroup=eachGroup.nextSibling;
eachOption=eachGroup.firstChild;
}
}
}
} catch(er){
alert(er);
}
document.formu.submit();

}


Bueno eso es por si a alguien se le ocurre realizar algo parecido...

Suerte!