【发布时间】:2011-11-15 22:02:54
【问题描述】:
我无法在 AsyncTask 的 doInBackground 方法中运行 ProgressDialog。它给了我以下错误:
ERROR/AndroidRuntime(12986): Caused by: java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
而错误就在代码的这一行:
final ProgressDialog dialog = ProgressDialog.show(GalleryView.this, "Refresh", "Loading... please wait", true);
非常感谢任何帮助。
【问题讨论】:
标签: android android-asynctask progressdialog