首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > Android >

2010.04.16————android 带输入框AlertDialog 第二次点击出现异常

2012-12-20 
2010.04.16————android带输入框AlertDialog 第二次点击出现错误2010.04.16————android带输入框AlertDialog

2010.04.16————android 带输入框AlertDialog 第二次点击出现错误
2010.04.16————android  带输入框AlertDialog 第二次点击出现错误

错误描述:
ERROR/AndroidRuntime(1394): java.lang.IllegalStateException: The specified child already has a parent. You must call removeView() on the child's parent first.

修改:

final View v = LayoutInflater.from(MainActivity.this).inflate(R.layout.login, null);


放到case里面来 每次创建时 都去加载R.layout.login 生成新的view 暂时解决了这个问题

热点排行