Exemplo n.º 1
0
        }//ShowError

        public static void HideError(this Android.Widget.EditText txtEdit)
        {
            txtEdit.SetError((string)null, null);
            txtEdit.SetCompoundDrawablesWithIntrinsicBounds(0, 0, 0, 0);
        }//HideError
Exemplo n.º 2
0
 /// <summary>
 /// ShowError
 /// </summary>
 /// <param name="txtEdit"></param>
 /// <param name="sErrorMsg"></param>
 public static void ShowError(this Android.Widget.EditText txtEdit, string sErrorMsg, Context cnt)
 {
     Android.Graphics.Drawables.Drawable icon = ContextCompat.GetDrawable(cnt, Resource.Drawable.val_error);
     txtEdit.SetError(sErrorMsg, null);
     txtEdit.SetCompoundDrawablesWithIntrinsicBounds(0, 0, Resource.Drawable.val_error, 0);
 }//ShowError