Validate form with preprocess_user_form I'm newbie on Drupal and I try to set an validation and submit the custom user registry form but I try and validation not call. 

function mymodule_theme(&amp;$existing, $type, $theme, $path){

  $hooks = array();
   // Make user-register.tpl.php available
  $hooks['user_register_form'] = array(
    'render element' =&gt; 'form',
    'path' =&gt; drupal_get_path('theme', 'mymodule') . '/templates',
    'template' =&gt; 'user-register',
    'preprocess functions' =&gt; array('mymodule_preprocess_user_register_form'),
  );
  return $hooks;

}

function mymodule_preprocess_user_register_form(&amp;$vars) {

  $vars['title'] = 'Registro de candidatas';
  $vars['message_welcome'] = '&lt;p&gt;Ingresar tu correo electrónico para iniciar este proceso. Asegúrate de tener abierto dicho correo para recibir las notificaciones y realizar de manera inmediata las indicaciones que recibas.&lt;/p&gt;';

  //Shortens the form variable name for easier access
  $form = $vars['form'];


  $form['account']['mail']['#attributes'] = array(
    'placeholder' =&gt; 'Escribe tu correo electrónico',
    'class' =&gt; array(
      'mymodule-form-email-input'
    )
  );
  $form['account']['mail']['#title_display'] = 'invisible';
  $form['account']['mail']['#description'] = '';

  $form['account']['pass']['pass1']['#title_display'] = 'invisible';
  $form['account']['pass']['pass1']['#attributes'] = array(
    'placeholder' =&gt; 'Escribe una contraseña',
    'class' =&gt; array(
      'mymodule-form-email-input'
    )
  );

  $form['account']['pass']['pass2']['#title_display'] = 'invisible';
  $form['account']['pass']['pass2']['#attributes'] = array(
    'placeholder' =&gt; 'Vuelve a escribir contraseña',
    'class' =&gt; array(
      'mymodule-form-email-input'
    )
  );

  $vars['mail'] = render($form['account']['mail']);
  $vars['pass'] = render($form['account']['pass']);
  $vars['captcha'] = render($form['captcha']);

}

function mymodule_user_register_form_alter(&amp;$form, &amp;$form_state, $form_id) {

  $form['account']['mail']['#field_prefix'] = '';
  $form['#validate'][] = 'mymodule_user_register_form_validate';

}

function mymodule_user_register_form_validate(&amp;$form, &amp;$form_state) {

  drupal_set_message(t('AN ERROR OCURED'));

  if ($form_state['values']['mail'] !== '') {
    form_set_error('mail', t('Escribe un correo electrónico'));
  } else {
    if(valid_email_address($form_state['values']['mail'])) {
      form_set_error('mail', t('Email invalido')); 
    }
  }

  if ($form_state['values']['pass']['pass1'] !== '') {
    form_set_error('mail', t('Escribe una contraseña')); 
  }

  if ($form_state['values']['pass']['pass2'] !== '') {
    form_set_error('mail', t('Confirma tu contraseña')); 
  }

  if ($form_state['values']['pass']['pass1'] !== $form_state['values']['pass']['pass2']) {
    form_set_error('mail', t('La contraseñas no coinciden')); 
  }

  if (!$form_state['values']['sendgift']) {
    form_set_error(NULL, '', TRUE);
    drupal_get_messages();
  }

}


Something I have wrong? I look on documentation and I found few details on registration. I read about hook_form_alter() and hook_preprocess_form() but it's confusing to me.

Thanks
The most obvious issue with your code is that you are trying to override the entire form structure within a theme preprocess hook. This does not work. Such hooks will be able to alter the output of forms or any other templates by providing additional variables, altering existing (theming) variables, or adding theme wrappers. They will not be able to alter the processing logic of a form.

Instead, you should manipulate your entire form within hook_form_FORM_ID_alter().

The second issue is, that your implementation of hook_form_FORM_ID_alter() is missing the _form_ part between mymodule and the form ID.

Also, consider using the t() function with English texts for all labels and add your desired translations to Drupal I stead of using hard-coded strings.