Bug? 8.8 problem with *.bal file

jatko

Member
Licensed User
I must install previous version, because of a big problem.

In my code there is a line:
Activity.LoadLayout("main_act")

in that step there is a bug listed below.
"main_act" is a normal "window" created in Designer. In previous version in works

Error occurred on line: 658 (Main)
java.io.FileNotFoundException: main_act.bal
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:207)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:82)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:351)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:144)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:180)
at anywheresoftware.b4a.debug.Debug.delegate(Debug.java:262)
at Sprzedaz.Mobilna.main._mainokno(main.java:1648)
at Sprzedaz.Mobilna.main._activity_create(main.java:1226)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:351)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:144)
at Sprzedaz.Mobilna.main.afterFirstLayout(main.java:104)
at Sprzedaz.Mobilna.main.access$000(main.java:17)
at Sprzedaz.Mobilna.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
 

jatko

Member
Licensed User
There is another problem after Your advice:

** Activity (main) Create, isFirst = true **
Serial1.Initialize()
main_activity_create (java line: 707)
java.lang.RuntimeException: java.io.FileNotFoundException: icudt46l.zip
at net.sqlcipher.database.SQLiteDatabase.loadICUData(SQLiteDatabase.java:150)
at net.sqlcipher.database.SQLiteDatabase.loadLibs(SQLiteDatabase.java:182)
at net.sqlcipher.database.SQLiteDatabase.loadLibs(SQLiteDatabase.java:169)
at anyhwheresoftware.b4a.objects.sqlcipher.SQLCipher.Initialize(SQLCipher.java:50)
at Sprzedaz.Mobilna.main._activity_create(main.java:707)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:196)
at Sprzedaz.Mobilna.main.afterFirstLayout(main.java:104)
at Sprzedaz.Mobilna.main.access$000(main.java:17)
at Sprzedaz.Mobilna.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
Caused by: java.io.FileNotFoundException: icudt46l.zip
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at net.sqlcipher.database.SQLiteDatabase.loadICUData(SQLiteDatabase.java:135)
... 18 more
java.lang.RuntimeException: java.io.FileNotFoundException: icudt46l.zip
 

jatko

Member
Licensed User
You're right, there was the old version of the library.
But when I change the version of the library the app can't open the old database file as database. I need to create the new one. After that I can lost some data. It rise big problem for my users.
I believe to solve that.
 

jatko

Member
Licensed User
I must return to the first question. The problem is unsolved. I have done Your first advice, off course.
I prepared the new catalog for the PC software for the new libraries. After that I have the same problem:

** Activity (main) Create, isFirst = true **
main_mainokno (java line: 6599)
java.io.FileNotFoundException: main_act.bal
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:207)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:82)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at Sprzedaz.Mobilna.main._mainokno(main.java:6599)
at Sprzedaz.Mobilna.main._activity_create(main.java:1027)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:191)
at Sprzedaz.Mobilna.main.afterFirstLayout(main.java:104)
at Sprzedaz.Mobilna.main.access$000(main.java:17)
at Sprzedaz.Mobilna.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
java.io.FileNotFoundException: main_act.bal
 

jatko

Member
Licensed User
The project I meant is too large. I send another, where problem seems to be the same.
 

Attachments

jatko

Member
Licensed User
Logger połączony z: 52034065ec1c9400
--------- beginning of system
--------- beginning of main
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Activity (main) Pause, UserClosed = true **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
main_activity_create (java line: 345)
java.io.FileNotFoundException: main.bal
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:207)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:82)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at sms.paczka.main._activity_create(main.java:345)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:191)
at sms.paczka.main.afterFirstLayout(main.java:104)
at sms.paczka.main.access$000(main.java:17)
at sms.paczka.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
main_activity_create (java line: 345)
java.io.FileNotFoundException: main.bal
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:207)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:82)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at sms.paczka.main._activity_create(main.java:345)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:191)
at sms.paczka.main.afterFirstLayout(main.java:104)
at sms.paczka.main.access$000(main.java:17)
at sms.paczka.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
main_activity_create (java line: 345)
java.io.FileNotFoundException: main.bal
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:207)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:82)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at sms.paczka.main._activity_create(main.java:345)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:191)
at sms.paczka.main.afterFirstLayout(main.java:104)
at sms.paczka.main.access$000(main.java:17)
at sms.paczka.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
 

jatko

Member
Licensed User
When I want to use Your code there is the message:

B4A line: 34
Log(f)
javac 1.8.0_191
src\sms\paczka\main.java:354: error: cannot find symbol
anywheresoftware.b4a.keywords.Common.LogImpl("0131075",_f,0);
^
symbol: method LogImpl(String,String,int)
location: class Common

I have must remove every "log" from project. That's another strange thing.

I used MsgBox(f)

result:
AutoRunTargetPermission.xml
images
pskc_schema.xsd
sound
webkit
 

jatko

Member
Licensed User
I removed every files from "library" catalog and after that I install 8.8 version b4a program. I discovered that when I run (F5) in debug mode, it works.

From code:

For Each f As String In File.ListFiles (File.DirAssets)
Log(f)
Next

I recieved:

inwentaryzacja (2).png
inwentaryzacja (3).png
logo3.jpg
main.bal
_assets_map

In Release mode it doesn't work

I recieved file list:

AutoRunTargetPermission.xml
images
pskc_schema.xsd
sounds
webkit

And log:

main_activity_create (java line: 358)
java.io.FileNotFoundException: main.bal
at android.content.res.AssetManager.openAsset(Native Method)
at android.content.res.AssetManager.open(AssetManager.java:350)
at android.content.res.AssetManager.open(AssetManager.java:324)
at anywheresoftware.b4a.objects.streams.File.OpenInput(File.java:207)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:82)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at sms.paczka.main._activity_create(main.java:358)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:196)
at sms.paczka.main.afterFirstLayout(main.java:104)
at sms.paczka.main.access$000(main.java:17)
at sms.paczka.main$WaitForLayout.run(main.java:82)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:145)
at android.app.ActivityThread.main(ActivityThread.java:6939)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1404)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1199)
 
Top