private Boolean ComprobarDatos() { Boolean OK = true; Notificador.Clear(); if (txtIdCaja.Text.Length == 0) { Notificador.SetError(txtIdCaja, "Campo obligatorio"); OK = false; } if (txtFecha.Text.Length == 0) { Notificador.SetError(txtFecha, "Campo obligatorio"); OK = false; } if (txtCantidad.Text.Length == 0) { Notificador.SetError(txtCantidad, "Campo obligatorio"); OK = false; } if (txtCantidad.TextLength > 0) { if (Double.Parse(txtCantidad.Text) <= 0) { Notificador.SetError(txtCantidad, "Digite una cantidad mayor a '0'"); OK = false; } } if (txtDescripcion.Text.Length == 0) { Notificador.SetError(txtDescripcion, "Campo obligatorio"); OK = false; } return(OK); }
private Boolean Verificacion() { Boolean Verificado = true; Notificador.Clear(); if (txbNombre.TextLength <= 0) { Verificado = false; Notificador.SetError(txbNombre, "Este campo debe llenarse"); } if (txbDescripcion.TextLength <= 0) { Verificado = false; Notificador.SetError(txbDescripcion, "Este campo debe llenarse"); } if (txbMunicipio.TextLength <= 0) { Verificado = false; Notificador.SetError(txbMunicipio, "Este campo debe llenarse"); } return(Verificado); }
private Boolean ValidarDatos() { Boolean Validado = true; Notificador.Clear(); if (txtPrimerNombre.TextLength == 0) { Notificador.SetError(txtPrimerNombre, "Este campo no puede quedar vacio."); Validado = false; } if (txtSegundoNombre.TextLength == 0) { Notificador.SetError(txtSegundoNombre, "Este campo no puede quedar vacio."); Validado = false; } if (txtPrimerApellido.TextLength == 0) { Notificador.SetError(txtPrimerApellido, "Este campo no puede quedar vacio."); Validado = false; } if (txtSegundoApellido.TextLength == 0) { Notificador.SetError(txtSegundoApellido, "Este campo no puede quedar vacio."); Validado = false; } if (txtTelefono.TextLength == 0) { Notificador.SetError(txtTelefono, "Este campo no puede quedar vacio."); Validado = false; } if (txtEmail.TextLength == 0) { Notificador.SetError(txtEmail, "Este campo no puede quedar vacio."); Validado = false; } if (txtDui.MaskCompleted == false || txtDui.TextLength == 0) { Notificador.SetError(txtDui, "Este campo no puede quedar vacio."); Validado = false; } if (txtResidencia.TextLength == 0) { Notificador.SetError(txtResidencia, "Este campo no puede quedar vacio."); Validado = false; } if (chkAsignarUsuario.Checked == true) { if (txtUsuario.TextLength == 0) { Notificador.SetError(txtUsuario, "Este campo no puede quedar vacio."); Validado = false; } if (txtPassword.TextLength == 0) { Notificador.SetError(txtPassword, "Este campo no puede quedar vacio."); Validado = false; } } return(Validado); }
private Boolean ValidarDatos() { Boolean Validado = true; Notificador.Clear(); if (txtPrimerNombre.TextLength == 0) { Notificador.SetError(txtPrimerNombre, "Este campo no puede quedar vacio."); Validado = false; } if (txtSegundoNombre.TextLength == 0) { Notificador.SetError(txtSegundoNombre, "Este campo no puede quedar vacio."); Validado = false; } if (txtPrimerApellido.TextLength == 0) { Notificador.SetError(txtPrimerApellido, "Este campo no puede quedar vacio."); Validado = false; } if (txtSegundoApellido.TextLength == 0) { Notificador.SetError(txtSegundoApellido, "Este campo no puede quedar vacio."); Validado = false; } if (DUI.MaskCompleted == false || DUI.TextLength == 0) { Notificador.SetError(DUI, "Este campo no puede quedar vacio."); Validado = false; } if (rbMasculino.Checked == false && rbFemenino.Checked == false) { Notificador.SetError(rbFemenino, "Este campo no puede quedar vacio."); Validado = false; } if (txtOcupacion.TextLength == 0) { Notificador.SetError(txtOcupacion, "Este campo no puede quedar vacio."); Validado = false; } if (txtResidencia.TextLength == 0) { Notificador.SetError(txtResidencia, "Este campo no puede quedar vacio."); Validado = false; } if (txtEmail.TextLength == 0) { Notificador.SetError(txtEmail, "Este campo no puede quedar vacio."); Validado = false; } if (txtTelefono.TextLength == 0) { Notificador.SetError(txtTelefono, "Este campo no puede quedar vacio."); Validado = false; } if (txtPersonaEmergencia.TextLength == 0) { Notificador.SetError(txtPersonaEmergencia, "Este campo no puede quedar vacio."); Validado = false; } if (txtTelefonoEmergencia.TextLength == 0) { Notificador.SetError(txtTelefonoEmergencia, "Este campo no puede quedar vacio."); Validado = false; } if (txtEstatura.TextLength == 0) { Notificador.SetError(txtEstatura, "Este campo no puede quedar vacio."); Validado = false; } if (txtPeso.TextLength == 0) { Notificador.SetError(txtPeso, "Este campo no puede quedar vacio."); Validado = false; } return(Validado); }