What to do on TransactionTooLargeException

前端 未结 30 3371
盖世英雄少女心
盖世英雄少女心 2020-11-22 03:08

I got a TransactionTooLargeException. Not reproducible. In the docs it says

The Binder transaction failed because it was too large.

D

30条回答
  •  悲哀的现实
    2020-11-22 03:42

    Also i was facing this issue for Bitmap data passing from one activity to another but i make a solution by making my data as static data and this is working perfect for me

    In activity first :

    public static Bitmap bitmap_image;
    
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_first);
       bitmap_image=mybitmap;
    }
    

    and in second activity :

     @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_second);
       Bitmap mybitmap=first.bitmap_image;
    }
    

提交回复
热议问题