I would like to know how can I set maximum length of text in an edittext control in android. I want the edittext to be able to handle large amount of text. How can I accomplish this. Thanks
try this
InputFilter[] FilterArray = new InputFilter[1];
FilterArray[0] = new InputFilter.LengthFilter(8);
editEntryView.setFilters(FilterArray);
In the xml declaration of the edittext you can add the atribute
android:maxLength="100" // or the size that you want
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With