android的textView中添加链接的时候,若链接为email,程序直接挂掉,求解决解决方法
android的textView中添加链接的时候,若链接为email,程序直接挂掉,求解决
在textview中的文字为:
请访问service@wangyi.com.
请访问http://baidu.com
试过了点解email的时候会直接挂,点击百度链接则可以,求大家帮忙
------解决方案--------------------
你去试试吧autolick 换成后面的值换成all
------解决方案--------------------
加一个解析器,单独处理
- Java code
<TextView android:id="@+id/text_body" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginLeft="30dip" android:layout_marginRight="0dip" android:layout_marginTop="8dip" android:autoLink="web|email" android:textColor="#000" android:textSize="14sp" />
- Java code
02-21 15:06:00.753: E/AndroidRuntime(14254): android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=mailto:xxxxxxx@xxxxxxx.xxx (has extras) }
在textview中的文字为:
请访问service@wangyi.com.
请访问http://baidu.com
试过了点解email的时候会直接挂,点击百度链接则可以,求大家帮忙
------解决方案--------------------
你去试试吧autolick 换成后面的值换成all
------解决方案--------------------
加一个解析器,单独处理