private bool ValidarNombre() { bool val = true; if (txt_name.Text.Trim() == "") { val = false; Validacion.SetError(txt_name, "Debe ingresar un tipo de hora."); } else if (!TextValidator.ValidarString(txt_name.Text)) { val = false; Validacion.SetError(txt_name, "El tipo de hora solo debe contener letras"); } if (txt_valor.Text.Trim() == "") { val = false; Validacion.SetError(txt_valor, "Debe ingresar el valor para el tipo de hora."); } else if (!TextValidator.ValidarFloat(txt_valor.Text)) { val = false; Validacion.SetError(txt_valor, "El valor de la hora debe contener solo numeros"); } return(val); }
private bool ValidarCampos() { bool val = true; if (txt_place.Text.Trim() == "") { val = false; Validaciones.SetError(txt_place, "Debe Ingresar un Lugar!"); } else if ((!TextValidator.ValidarStringEntero(txt_place.Text) && !TextValidator.ValidarString(txt_place.Text))) { val = false; Validaciones.SetError(txt_place, "Debe ingresar un lugar valido!"); } if (txt_hrs.Text.Trim() == "") { val = false; Validaciones.SetError(txt_hrs, "Debe ingresar las horas trabajadas!"); } else if (!TextValidator.ValidarFloat(txt_hrs.Text)) { val = false; Validaciones.SetError(txt_hrs, "Las hora pueden ser unicamente numeros!"); } return(val); }
private bool ValidarCampos() { bool val = true; if (txt_Nombre.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Nombre, "Debe Ingresar un Nombre!"); } else if (!TextValidator.ValidarString(txt_Nombre.Text)) { val = false; Validaciones.SetError(txt_Nombre, "El nombre debe contener unicamente letras!"); } if (txt_Apellido.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Apellido, "Debe Ingresar un Apellido!"); } else if (!TextValidator.ValidarString(txt_Apellido.Text)) { val = false; Validaciones.SetError(txt_Apellido, "El Apellido debe contener unicamente letras!"); } if (txt_Telefono.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Telefono, "Debe Ingresar un Telefono!"); } else if (!TextValidator.ValidarTelefono(txt_Telefono.Text)) { val = false; Validaciones.SetError(txt_Telefono, "Ingrese un telefono valido!"); } if (txt_Domicilio.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Domicilio, "Debe Ingresar un Domicilio!"); } else if (!TextValidator.ValidarStringEntero(txt_Domicilio.Text)) { val = false; Validaciones.SetError(txt_Domicilio, "Debe ingresar un domicilio valido!"); } return(val); }
private bool ValidarNombre() { bool val = true; if (txt_name.Text.Trim() == "") { val = false; Validacion.SetError(txt_name, "Debe ingresar una profesion."); } else if (!TextValidator.ValidarString(txt_name.Text)) { val = false; Validacion.SetError(txt_name, "El nombre de la profesion solo debe contener letras"); } return(val); }
private bool ValidarNombre() { bool val = true; if (txt_name.Text.Trim() == "") { val = false; Validaciones.SetError(txt_name, "El nombre de la obra social es obligatorio"); } else if (!TextValidator.ValidarString(txt_name.Text)) { val = false; Validaciones.SetError(txt_name, "El nombre de la obra social solo debe contener letras"); } return(val); }
private bool ValidarCampos() { bool val = true; if (txt_Codigo.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Codigo, "Debe ingresar un codigo!"); } else if (!TextValidator.ValidarEntero(txt_Codigo.Text)) { val = false; Validaciones.SetError(txt_Codigo, "El codigo es unicamente numerico"); } if (txt_Producto.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Producto, "Debe Ingresar un Producto!"); } else if (!TextValidator.ValidarStringEntero(txt_Producto.Text) && (!TextValidator.ValidarString(txt_Producto.Text))) { val = false; Validaciones.SetError(txt_Producto, "Producto mal ingresado!"); } if (txt_Precio.Text.Trim() == "") { val = false; Validaciones.SetError(txt_Precio, "Debe Ingresar un Precio para el producto!"); } else if (!TextValidator.ValidarFloat(txt_Precio.Text)) { val = false; Validaciones.SetError(txt_Precio, "El precio del producto debe ser numero y con 2 decimales"); } return(val); }
private bool ValidarCampos() { bool val = true; if (txt_name.Text.Trim() == "") { val = false; Validaciones.SetError(txt_name, "Debe Ingresar un Nombre!"); } else if (!TextValidator.ValidarString(txt_name.Text)) { val = false; Validaciones.SetError(txt_name, "El nombre debe contener unicamente letras!"); } if (txt_ape.Text.Trim() == "") { val = false; Validaciones.SetError(txt_ape, "Debe Ingresar un Apellido!"); } else if (!TextValidator.ValidarString(txt_ape.Text)) { val = false; Validaciones.SetError(txt_ape, "El Apellido debe contener unicamente letras!"); } if (txt_tel.Text.Trim() == "") { val = false; Validaciones.SetError(txt_tel, "Debe Ingresar un Telefono!"); } else if (!TextValidator.ValidarTelefono(txt_tel.Text)) { val = false; Validaciones.SetError(txt_tel, "Ingrese un telefono valido!"); } if (txt_dom.Text.Trim() == "") { val = false; Validaciones.SetError(txt_dom, "Debe Ingresar un Domicilio!"); } else if (!TextValidator.ValidarStringEntero(txt_dom.Text)) { val = false; Validaciones.SetError(txt_dom, "Debe ingresar un domicilio valido!"); } if (txt_doc.Text.Trim() == "") { val = false; Validaciones.SetError(txt_doc, "Debe Ingresar un documento!"); } else if (!TextValidator.ValidarEntero(txt_doc.Text)) { val = false; Validaciones.SetError(txt_doc, "Debe ingresar un documento valido!"); } if (txt_mat.Text.Trim() == "") { val = false; Validaciones.SetError(txt_mat, "Debe Ingresar una matricula!"); } else if (!TextValidator.ValidarEntero(txt_mat.Text)) { val = false; Validaciones.SetError(txt_mat, "Debe ingresar una matricula valida!"); } if (txt_mail.Text.Trim() == "") { val = false; Validaciones.SetError(txt_mail, "Debe Ingresar un mail!"); } else if (!TextValidator.ValidarMail(txt_mail.Text)) { val = false; Validaciones.SetError(txt_mail, "Debe ingresar un mail valido!"); } return(val); }