android - How to make links in textview clickable -
how make links clickable in text view. problem
(1). view.setmovementmethod(linkmovementmethod.getinstance()); works when textview contains link(anchor tag/href) this:
<a href="http link">go google</a> it does'nt work when textview contains link this: http link
(2). while android:autolink="web" works when textview contains link this: http link does'nt work when textview contains link this:
<a href="httplink">go google</a> what when textview contains both types of link. please help.
try this
textview.setonclicklistener(new view.onclicklistener()); in xml:
android:clickable="true" or can use string
htmltext=html.fromhtml(htmltext) then set htmltext textview
textview.settext(htmltext)
Comments
Post a Comment