private int doAddOrEdit = 1;
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.addmodel);
Bundle bun = this.getIntent().getExtras();
doAddOrEdit = bun.getInt("which"); //bun空指针异常,但明明有定义啊。
...
}
解决方案 »
- error: Error retrieving parent for item: No resource found that matches the give
- 获得SIM卡的CCID除了getSimSerialNumber还有别的办法吗
- 为什么我这个这么简单的webview就是上不了网呢?
- ACTION_BATTERY_CHANGED什么时候广播?
- 求解答:error: Error parsing XML: unbound prefix
- 分享快速入门android应用开发的心得
- 新人求助,关于编写一个android下简单的voip的程序
- m_message是QPushButton
- 问一个安卓开发SDK 方面的问题
- android中的一些疑问
- 安装软件时, 显示共享用户权限不完整
- 关于Android蓝牙方面
data.putInt("which",1);
Intent intent = new Intent(Model.this,AddModel.class);
intent.putExtras(intent);
startActivity(intent);