Exemplo n.º 1
0
int WINAPI LocalIsalphanum(unsigned Ch)
{
	if (Ch>=256)
		return FALSE;

	char CvtCh=Ch;
	OemToCharBuffA(&CvtCh,&CvtCh,1);
	return(IsCharAlphaNumericA(CvtCh));
}
Exemplo n.º 2
0
BOOL
ValidateCoinstallerVersion(
    _In_ PSTR Version
    )
{   BOOL ok = FALSE;
    INT i;

    for(i= 0; i<MAX_VERSION_SIZE ;i++){
        if( ! IsCharAlphaNumericA(Version[i])) {
            break;
        }
    }
    if (i == (MAX_VERSION_SIZE -sizeof(CHAR))) {
        ok = TRUE;
    }
    return ok;
}
Exemplo n.º 3
0
bool Persona::validarCI(String ci)
{
        if(ci.Length()==0){
                ShowMessage("La Cédula es obligatoria, no puede estar vacia...");
                return 0;
        }
        if(ci.Length()<6||ci.Length()>8){
                ShowMessage("El campo Cédula admite entre 6 y 8 digitos");
                return 0;
        }
        char *a=ci.c_str();
        for(int i=0;i<=ci.Length()-1;i++){
                if(!IsCharAlphaNumericA(a[i])){
                        ShowMessage("El campo Cédula admite solo números entre 0 y 9");
                        return 0;
                }
        }
        return 1;
}