// JavaScript Document


function validaForm(){
        d = document.cadastro;
		valor = d.inscricao.value;
		cpf = d.cpf.value;
		if ( valor.length < 1 && cpf.length < 1){
        	alert("Pelo menos um dos campos deve ser preenchido!");                    
		 	d.inscricao.focus();
            return false;
		}

}

function SomenteNumero(e){
    var tecla=(window.event)?event.keyCode:e.which;
    if((tecla > 47 && tecla < 58)) return true;
    else{
    if (tecla != 8) return false;
    else return true;
    }
}

function validaForm2(){
        d = document.cadastro;
		valor = d.matricula.value;
		cpf = d.cpf.value;
		if ( valor.length < 1 || cpf.length < 1){
        	alert("Todos os campos devem ser preenchidos.");                    
		 	d.matricula.focus();
            return false;
		}
}
