hi
i am using ArchiverPlus lib made by @Informatix and i am getting crashes when i try to use it.
is it a problem in the lib or maybe in my code??
this is my code:
i am using ArchiverPlus lib made by @Informatix and i am getting crashes when i try to use it.
*** Service (starter) Create ***
6
jd: 2458313.0705875
Freitag:
19:50 | 16:41:38
zmanit:10
shabbat = false
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
*** Service (firebasemessaging) Create ***
** Service (firebasemessaging) Start **
subscribe to topics called
adview1: received ad
main_archiver_zipresult (java line: 988)
java.lang.RuntimeException: Can't create handler inside thread that has not called Looper.prepare()
at android.os.Handler.<init>(Handler.java:203)
at android.os.Handler.<init>(Handler.java:117)
at android.app.Dialog.<init>(Dialog.java:142)
at android.app.AlertDialog.<init>(AlertDialog.java:201)
at android.app.AlertDialog.<init>(AlertDialog.java:197)
at android.app.AlertDialog.<init>(AlertDialog.java:142)
at android.app.ProgressDialog.<init>(ProgressDialog.java:105)
at android.app.ProgressDialog.show(ProgressDialog.java:209)
at android.app.ProgressDialog.show(ProgressDialog.java:189)
at anywheresoftware.b4a.keywords.Common.ProgressDialogShow2(Common.java:731)
at www.sagital.buysmart.main._archiver_zipresult(main.java:988)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:191)
at a.a.a.f.a.a(SourceFile:88)
at a.a.a.f.a.c(SourceFile:155)
at a.a.a.f.a.a(SourceFile:163)
at a.a.a.i.a.a(SourceFile:190)
at a.a.a.i.a$1.run(SourceFile:1101)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:457)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at java.lang.Thread.run(Thread.java:764)
is it a problem in the lib or maybe in my code??
this is my code:
B4X:
Arc.AddFilesToZip(filelist,File.DirInternal & "/" & myuserid & ".zip","Archiver")
Sub Archiver_ZipResult(Result As Int, ErrorMsg As String)
Select Result
Case Arc.ZIP_RESULT_SUCCESS
Select zipid
Case 0
If File.Exists(File.DirInternal, myuserid & ".zip") Then
ProgressDialogShow2(stringconvert.returnStr(55),False)
initializecl
uploadnow
End If
Case 1
Log("SUCCESSFULLY unzipped")
loadcontacts
End Select
Case Arc.ZIP_RESULT_ERROR
Select zipid
Case 0
ToastMessageShow(stringconvert.returnStr(56),False)
Log("error creating zip: " & ErrorMsg)
Case 1
ToastMessageShow(stringconvert.returnStr(57),False)
Log("error creating zip: " & ErrorMsg)
End Select
End Select
End Sub