2013-02-08 77 views
3

我有一個listview,其中每個listitem都有一個圖像和4個textview。我只想更改2個文字瀏覽而不更改列表和項目列表。 這些文字瀏覽每秒都會更改。 在android中可能嗎?如何在不更改項目列表的情況下更改listview內容

+0

是其可能的。 – 2013-02-08 11:42:04

+0

對這些列表使用runonUIthread。並不斷更新項目 – 2013-02-08 11:42:15

+0

,但它刷新總的列表視圖我想更新只有一個文本視圖 – saritha 2013-02-11 10:27:44

回答

0

您可以更新的ListView的文本項是這樣的:

private void updateText(int index){ 
View v = ListView.getChildAt(index); 

TextView updatedText = (TextView) v.findViewById(R.id.txt_view); 
updatedText .setText("changed Text"); 

} 
+0

這是否解決你的問題? – user1969053 2013-02-11 06:34:04

相關問題