I have created an app which scrapes text from a website but sometimes the amount of data is larger than the Android device can handle and the app stops dead with 'Unfortunately, AppName has stopped.'
The following code simulates this :-
How do I trap for this so that I can warn the user and recover from the exception ?.
Note, I am not asking about how to avoid out-of-memory per se.
Best Regards
Del, England +++
The following code simulates this :-
B4X:
Dim sBigString As String = "XXXXXXXXXXX"
Do Until sBigString = "never"
Try
sBigString = sBigString & sBigString
Catch
Log (LastException)
End Try
Loop
How do I trap for this so that I can warn the user and recover from the exception ?.
Note, I am not asking about how to avoid out-of-memory per se.
Best Regards
Del, England +++