android activity跳转传类出错

来源:互联网 发布:sql over 用法 编辑:程序博客网 时间:2024/06/06 01:42

android activity跳转时传 list 中放类会出错

Intent intent =new intent();intent.setClass(this,B.class);intent.putExtax("nsrxxList",nsrList<Nsrxx>);startActivity(intent);

1,新建一个activity,添加进去的时候,记得在androidmainfest.xml中注册,否则会报如下

android.content.activityNotFoundException:unable to find explicit activity class

2,传输一个List nsrxxLIst,
android java.lang.runtimeexception:parcel:unable to marshal value 报错
点击查看详细stackoverflow
解决方法:

public class Nsrxx implements Serializable
0 0