Showing only the first 10 symbols in each list item in listview in android project -
i have message scheme , listview hold messages.so want show let's first 10 symbols of message , after ellipsis.i couldn't find info how it, if can help me.
i assume know how set adapter.
you can accomplish editing xml layout file. limit max amount of text textview can hold, , tell add together ellipsis if it's longer.
<textview android:id="@+id/secondlinetextview" android:layout_width="wrap_content" android:layout_height="wrap_content" android:maxlines="1" android:maxlength="10" android:ellipsize="end"/>
example here
android listview
No comments:
Post a Comment