Android Question CustomListView - Transaction too large crash when going to pause.

alon

Active Member
Licensed User
Longtime User
Hi ,

I have a problem with my app in some devices.

the problem is that when my app going to pause, it crash with Transaction too large.


I saw a post from jmon ( https://www.b4x.com/android/forum/threads/solved-transaction-too-large-crash.100292/#content )
with the same problem saying that when we have a lot of items on the CustomListView, the app is crash.
and that is the same problem that I have.


I would like to know if there are other solutions for the problem?


p.s

His solutions was to clear the list before going to pause and refill it on resume,
or to use the standard listview.



Thanks
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
The error happened because the "activity" color is a gradient color.
It shouldn't have crashed. You've hit a bug in XUI library that caused this crash. It is fixed for the next update.

You should set the background color to a solid color (or the default color). If you like to have an item with a gradient color then add a panel and set its background (with the designer).
 
Upvote 0

alon

Active Member
Licensed User
Longtime User
The error happened because the "activity" color is a gradient color.
It shouldn't have crashed. You've hit a bug in XUI library that caused this crash. It is fixed for the next update.

You should set the background color to a solid color (or the default color). If you like to have an item with a gradient color then add a panel and set its background (with the designer).

Greate Thanks a lot.

It will be in the next update of b4a?
 
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
It will be in the next update of b4a?
in the next XUI Library Update. This can be also the next b4a update ;-)
I guess XUI will be released as internal library update first/sooner.
 
Upvote 0

alon

Active Member
Licensed User
Longtime User
Note that you should still use a solid color. B4XView.Color will just not crash and return a transparent color instead.

Thanks.

sorry but now i am having a different problem with the listview.
the following code is not working:

clv.AsView.Width = 100%x
clv.AsView.Height = 80%y


I have notice that the clv.widh is being smaller only after the createitemlist Sub
if I will skip the createitemlist Sub the the clv.width is 100%x

Am i missing a configuration?

Thanks
 
Last edited:
Upvote 0

alon

Active Member
Licensed User
Longtime User
Ok I think I found the problem.

now when i am adding this code:
clv.sv.Height = 80%y
the scroll is showing all over the listview

the only problem that I have now is that the item panel is not in the same width of list view.
I was trying to write this code but still the same.

clv.sv.Left = 0
clvDoh.sv.Width = 100%x
 

Attachments

  • bb.jpg
    bb.jpg
    49.9 KB · Views: 160
Upvote 0
Top