-1

I'm trying to make a log in menu where there are 2 edit texts with hints in them. One hint is "Correo electrónico" and the other one "Contraseña".

I've tried using android:hint and changing the android:textColorHint but none of them worked. I've also tried all the answers given here EditText hint doesn't show

This is my xml Edit Text code.

            <EditText
                android:id="@+id/editTxtMail"
                android:layout_width="325dp"
                android:layout_height="41dp"
                android:layout_marginTop="35dp"
                android:background="@drawable/roundededittext"
                android:drawableLeft="@drawable/perfil"
                android:drawablePadding="10dp"
                android:elevation="10dp"
                android:hint="Correo electrónico"
                android:ellipsize="end"
                android:paddingLeft="10dp"
                android:textColorHint="#858585" />

            <EditText
                android:id="@+id/editTextPssw"
                android:layout_width="325dp"
                android:layout_height="41dp"
                android:layout_marginTop="25dp"
                android:background="@drawable/roundededittext"
                android:bottomLeftRadius="15dp"
                android:bottomRightRadius="15dp"
                android:drawableLeft="@drawable/lock"
                android:drawablePadding="10dp"
                android:elevation="10dp"
                android:hint="Contraseña"
                android:inputType="textPassword"
                android:paddingLeft="10dp"
                android:textColorHint="#858585"
                android:ellipsize="end"
                android:topLeftRadius="15dp"
                android:topRightRadius="15dp" />

In the preview window of android studio it shows with both hints, but when I run the app both hints doesn't appear. The other part of the log in screen is perfectly showed.

MikelMoli
  • 1
  • 2

1 Answers1

0

I found the problem. I don't know why but there where 2 layouts with the same name but different version:

log_in.xml and log_in_xml(v.11).

The answers weren't working because I was changing the layout that didn't match the running class. It was that simple.

MikelMoli
  • 1
  • 2