1.使用findViewbyID方法没有加强制类型转换 例如: b1=(Button)findViewById(R.id.button2); 如果没有(Button)程序调试可能就不能正常运行 发现了其他原因再添加