的ActivityGroup的儿童中微调不起作用 [英] Spinner within Child of ActivityGroup doesn't work
本文介绍了的ActivityGroup的儿童中微调不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个活动里面微调,活动组发现孩子的问题。
当我点击了微调,即不扩大,强制关闭窗口出现
我被检查logcat的,赶上BadTokenException,见下图:
I have a problem with spinner inside activity , that child of Activity group . when I clicked on spinner , that isn't expanded and "Force Close" window appears I was checked Logcat and catch "BadTokenException ", see below :
http://i227.photobucket.com/albums/dd299/薰衣草-90 / stackflow.jpg
我的XML:
<Spinner
android:id="@+id/aroundSP"
android:layout_height="wrap_content"
android:prompt="@string/touraround"
android:layout_width="fill_parent"
android:entries="@array/Triparound"
android:layout_marginTop="250dip"
android:layout_marginLeft="4dip"
style="@style/ContentTitle">
</Spinner>
谢谢大家!
推荐答案
这工作得很好。
View viewToLoad = LayoutInflater.from(this.getParent()).inflate(
R.layout.marketlist, null);
this.setContentView(viewToLoad);
这篇关于的ActivityGroup的儿童中微调不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文