I have a requirement that Edittext
should have all words start with Capital letter. If the user writes it in a smaller case(first letter of the word), then also it should be converted it into Uppercase
.
I have done it in layout as below so far :
<EditText
android:id="@+id/edGymName"
style="@style/LoginRegisterEditText"
android:layout_marginTop="@dimen/size_10"
android:layout_toLeftOf="@+id/txtStatusGymStatus"
android:hint="@string/gym_tag"
android:inputType="textPersonName|textCapWords|textNoSuggestions"
android:maxLength="30" />
But, I don't want to allow the user to write the first letter of the word in the small letter. This is working but the user is able to write the first letter of the word in the small case
. What if we forcefully do not allow it.