Android Question I want to know because there is a log limit of 4000 chars but B4A is able to show longer logs

max123

Well-Known Member
Licensed User
Longtime User
Hi all,

many peoples in the past have asked about the log truncation limit of 4000 characters.

To fix this I wrote a small library capable to show longer logs without truncate them and without show the warning.
My library now works pretty well apart some small things.

The problem here is that, after I created a library, I've created a demo code, to compare my library vs Log command
and here I see that B4A log already can show logs longer than 4000 characters, it show a warning, but logs longer
than 4000 characters seem are fully printed out. o_O

Now I want to know, something has changed in Android or B4A about this from the past ?
My library have some sense or B4A can do it itself ?

Attached a screenshot with my library in action, here I log a 50000+ characters long string.
The library can even enumerate lines.

Thanks
 

Attachments

  • Screenshot 2024-04-23 120134.png
    Screenshot 2024-04-23 120134.png
    155.7 KB · Views: 90
  • Screenshot 2024-04-23 121103.png
    Screenshot 2024-04-23 121103.png
    163.8 KB · Views: 95
Last edited:

max123

Well-Known Member
Licensed User
Longtime User
My problem is not that I have a limit, but that the limit don't happen at all.

The purpose of my library is not to log to a file, but to log to a log view of the IDE.

As for my thread title I want to know because now B4A can print longer logs in one single log command (not truncated),
it show a warning but I can print a 15000 chars string and seem it is now printed without problems.

Note that I test it with emulator and SDK 33.

Something has changed from past ?
Because log limit depends not by B4A (I think) but by Android itself, this may depends by Android SDK version ?
There's no really limit of 4000 chars now ?
And if yes, because the warning shows on the log after a full long log is printed out ?

Thanks
 
Last edited:
Upvote 0
Top