里面报错
Caused by: android.view.InflateException: Binary XML file line #29: Error inflating class <unknown>
Caused by: java.lang.reflect.InvocationTargetException
Caused by: java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
其实我29行是一个Spinner
<Spinner
android:id="@+id/number_type"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="2" />
大概操作是 在 AsyncTask 中的 doInBackground 操作界面 出现这个问题
最后在 doInBackground 方法中加入
Looper.prepare();
Ok了