제 문제는 동일한 레이아웃에서 두 개의 동일하게 정의 된 링크를 열 수 없다는 것입니다. 첫 번째 단추를 길게 누르면 "URL 복사"라는 상황에 맞는 메뉴가 표시되지만 두 번째 경우에는 그렇지 않습니다. 링크는 유효한 것입니다. 여기 동일한 Android 레이아웃에서 두 개 이상의 링크를 사용할 수 없습니다.
정의 두 textviews 있습니다 : 나는 모토로라 디파이 (요르단)에 안드로이드 2.3.7 (사이 애 노젠 모드)와 사용자 정의 ROM을 실행하는거야<TextView
android:id="@+id/txt_id1"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:autoLink="web"
android:gravity="center_horizontal"
android:linksClickable="true"
android:text="@string/text1"
android:textColor="@color/white"
android:textColorHighlight="@color/white"
android:textSize="18sp" />
<TextView
android:id="@+id/txt_id2"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:autoLink="web"
android:gravity="center_horizontal"
android:linksClickable="true"
android:text="@string/text2"
android:textColor="@color/white"
android:textColorHighlight="@color/white"
android:textSize="18sp" />
. 에뮬레이터에서 시도했지만 작동하지 않습니다.
모든 답변을 잘 부탁드립니다.
편집 :
<string name="text1"><a href="http://www.google.com">http://www.google.com</a></string>
<string name="text2"><a href="http://www.wikipedia.org">Text2</a></string>
텍스트 1과 텍스트 2의 실제 텍스트는 무엇입니까? –
"android : text ="@ string/text2 "및"android : text = "@ string/text2"를 확인하십시오. 또한 "android : id ="@ + id/txt_id2 "및"android : id = "@ + id/txt_id1" – anoop