- 2011-09-24 (土) 21:28
- 未分類
メモです。
AsyncTaskで処理をしているのに、Only the original thread that created a view hierarchy can touch its views.が出る場合。
→doInBackgroundでUIを触ってませんか?onPreExecuteかonPastExecuteで対応しましょう。
この問題、doInBackbroundでは2回目のアクセスの時に落ちるので、発見しにくいです。
コメント:2
トラックバック:0
- このエントリーのトラックバックURL
- http://codedesign.jp/blog/2011/09/24/asynctask%e3%81%a7only-the-original-thread-that-created-a-view-hierarchy-can-touch-its-views/trackback/
- Listed below are links to weblogs that reference
- AsyncTaskでOnly the original thread that created a view hierarchy can touch its views. from codedesign.jp