コード例 #1
0
ファイル: FrmGetBackup.cs プロジェクト: etijera/RecordRatings
 private void TxtUsuario_Validating(object sender, CancelEventArgs e)
 {
     if (string.IsNullOrEmpty((TxtUbicacion.Text)))
     {
         errorP1.SetError(TxtUbicacion, "Debe ingresar la ubicación.");
         TxtUbicacion.Focus();
     }
     else
     {
         errorP1.SetError(TxtUbicacion, "");
     }
 }
コード例 #2
0
ファイル: FrmGetBackup.cs プロジェクト: etijera/RecordRatings
        public bool Validar()
        {
            bool retorno = true;

            if (string.IsNullOrEmpty((TxtUbicacion.Text)))
            {
                errorP1.SetError(TxtUbicacion, "Debe ingresar la ubicación.");
                TxtUbicacion.Focus();
                retorno = false;
            }
            else
            {
                errorP1.SetError(TxtUbicacion, "");
            }

            return(retorno);
        }