java - textview on arraylist Android -


my "stress" place hyperlink on item of arraylist. dont have textview on xml, simple listview.

private void preparelistdata() {     listdataheader = new arraylist<string>();     listdatachild = new hashmap<string, list<string>>();     //header      listdataheader.add("text example");     //itens     list<string> itemal = new arraylist<string>();     itemal .add("text example");     itemal .add(**"watch clip - http://videos.sapo.pt/testtesttest**");     listdatachild.put(listdataheader.get(0), itemal ); } 

and xml file:

<relativelayout...     <listview         android:layout_margintop="100dp"         android:id="@+id/lvexp4"         android:layout_height="match_parent"         android:layout_width="match_parent"         tools:listitem="@android:layout/simple_list_item_checked" /> </relativelayout> 

first of create adapter listview,and set textview per requirements ,

use property in textview attribute :-

android:autolink="web" 

Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -