function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function  EW_checkMyForm(EW_this) {
if (EW_this.x_descricao && !EW_hasValue(EW_this.x_descricao, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_descricao, "TEXT", "Nome Obrigatório."))
                return false; 
        }
if (EW_this.x_morada && !EW_hasValue(EW_this.x_morada, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_morada, "TEXT", "Morada Obrigatória."))
                return false; 
        }
if (EW_this.x_localidade && !EW_hasValue(EW_this.x_localidade, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_localidade, "TEXT", "Localidade Obrigatória."))
                return false; 
        }
if (EW_this.x_cp && !EW_hasValue(EW_this.x_cp, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_cp, "TEXT", "Código Postal Obrigatório (ex:xxxx-xxx)."))
                return false; 
        }

if (EW_this.x_cp && !EW_checkzip(EW_this.x_cp.value)) {
        if (!EW_onError(EW_this, EW_this.x_cp, "TEXT", "Código Postal inválido (ex:xxxx-xxx)."))
            return false; 
        }
		
if (EW_this.x_id_distrito && !EW_hasValue(EW_this.x_id_distrito, "SELECT" )) {
            if (!EW_onError(EW_this, EW_this.x_id_distrito, "SELECT", "Seleccione Distrito"))
                return false; 
        }
if (EW_this.x_id_concelho && !EW_hasValue(EW_this.x_id_concelho, "SELECT" )) {
            if (!EW_onError(EW_this, EW_this.x_id_concelho, "SELECT", "Seleccione Concelho"))
                return false; 
        }

if (EW_this.x_freguesia && !EW_hasValue(EW_this.x_freguesia, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_freguesia, "TEXT", "Freguesia Obrigatória."))
                return false; 
        }

if (EW_this.x_telefone && !EW_hasValue(EW_this.x_telefone, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_telefone, "TEXT", "Telefone Obrigatório (ex:xxxxxxxxx)."))
                return false; 
        }
if (EW_this.x_telefone && !EW_checkphone(EW_this.x_telefone.value)) {
        if (!EW_onError(EW_this, EW_this.x_telefone, "TEXT", "Telefone Incorrecto (ex:xxxxxxxxx)."))
            return false; 
        }
if (EW_this.x_fax && !EW_checkphone(EW_this.x_fax.value)) {
        if (!EW_onError(EW_this, EW_this.x_fax, "TEXT", "Fax Incorrecto (ex:xxxxxxxxx)."))
            return false; 
        }
if (EW_this.x_e_mail && !EW_checkemail(EW_this.x_e_mail.value)) {
        if (!EW_onError(EW_this, EW_this.x_e_mail, "TEXT", "Email Incorrecto"))
            return false; 
        }
if (EW_this.x_n2003 && !EW_hasValue(EW_this.x_n2003, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_n2003, "TEXT", "Voluntários 2003 - valor inválido."))
                return false; 
        }
if (EW_this.x_n2003 && !EW_checkinteger(EW_this.x_n2003.value)) {
        if (!EW_onError(EW_this, EW_this.x_n2003, "TEXT", "Voluntários 2003 - valor inválido."))
            return false; 
        }
if (EW_this.x_ndirigentes2003 && !EW_hasValue(EW_this.x_ndirigentes2003, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_ndirigentes2003, "TEXT", "Dirigentes Associativos 2003 - valor inválido."))
                return false; 
        }
if (EW_this.x_ndirigentes2003 && !EW_checkinteger(EW_this.x_ndirigentes2003.value)) {
        if (!EW_onError(EW_this, EW_this.x_ndirigentes2003, "TEXT", "Dirigentes Associativos 2003 - valor inválido."))
            return false; 
        }

if (EW_this.x_nactual && !EW_hasValue(EW_this.x_nactual, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_nactual, "TEXT", "Voluntários Actualmente - valor inválido."))
                return false; 
        }
if (EW_this.x_nactual && !EW_checkinteger(EW_this.x_nactual.value)) {
        if (!EW_onError(EW_this, EW_this.x_nactual, "TEXT", "Voluntários Actualmente - valor inválido."))
            return false; 
        }
if (EW_this.x_ndirigentesactual && !EW_hasValue(EW_this.x_ndirigentesactual, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_ndirigentesactual, "TEXT", "Dirigentes Associativos Actualmente - valor inválido."))
                return false; 
        }
if (EW_this.x_ndirigentesactual && !EW_checkinteger(EW_this.x_ndirigentesactual.value)) {
        if (!EW_onError(EW_this, EW_this.x_ndirigentesactual, "TEXT", "Dirigentes Associativos Actualmente - valor inválido."))
            return false; 
        }		
		
if (EW_this.x_nome_responsavel && !EW_hasValue(EW_this.x_nome_responsavel, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_nome_responsavel, "TEXT", "Nome do Responsável Obrigatório."))
                return false; 
        }
		
if (EW_this.x_data_responsavel && !EW_hasValue(EW_this.x_data_responsavel, "TEXT" )) {
            if (!EW_onError(EW_this, EW_this.x_data_responsavel, "TEXT", "Data Obrigatória."))
                return false; 
		}	
		

return true;
}
