Android Question Empty Edittext filled with the Enterkey

Discussion in 'Android Questions' started by appie21, Aug 17, 2015.

  1. appie21

    appie21 Active Member Licensed User


    I try to safe data from a Edittext (multiline)

    If the user fill nothing in that EditTextbox i give a message

    If EditText.text = "" Then
    Messagebox("Fill in the form", "Hello")

    if the user press the enter key once or more times it place emty lines in my Edit textbox (and no more text)

    The code "If EditText.text = "" Then" will not work (because EditText.text.Length give 1 or more

    How can I set a Messagebox to a "visual" emty Edittextbox?
  2. eurojam

    eurojam Well-Known Member Licensed User

    you can replace the line feed before you do your code like this:
    txt = EditText.text
    txt = txt.replace(
    If txt = "" Then
    "Fill in the form""Hello")
    end if
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice