Android Question Saving Crash log

DeviousD

Member
Licensed User
Longtime User
Hi All,
We are having some crashes on certain devices outside of the norm and as we are not using other services like firebase we would like to push these error logs back to the server so i can work out whats going on.

So without implementing Crashlytics how can i save the log after the app has crashed?

I will bundle that up and upload it to my server for analysis, i simply need a way to save the log with all its information into a file.

How can this be done or should i wrap each activity into a try catch and do it that way rather?

i'm guessing i have kind of answered my own question on this, but i did search saving crash logs, so maybe when someone else searches for that they might be a little advice how to make their logging easier and their APP more robust.

Any suggestions etc that can be tagged on here for me and also others wanting to do the save crash log..
 

agraham

Expert
Licensed User
Longtime User
There is an Application_Error event in the Starter service that can trap crashes. You can try using that.
B4X:
'Return true to allow the OS default exceptions handler to handle the uncaught exception.
Sub Application_Error (Error As Exception, StackTrace As String) As Boolean
    Return True
End Sub
 
Upvote 0

DeviousD

Member
Licensed User
Longtime User
If you didnt find it right away, here is some more information

 
Upvote 0
Top