Android Question Release mode on tablet not working

Ricky D

Well-Known Member
Licensed User
Longtime User
this is my code

Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
Private lstSuburbs As List
lstSuburbs.Initialize

sql.Initialize("/storage/emulated/0","Taxi.sqlite",False)
Msgbox("hello","")
Private cur As Cursor
cur = sql.ExecQuery("Select Suburb From Suburbs Order by Suburb Desc")
cur.Position=0

'Msgbox(cur.RowCount,"")

Activity.LoadLayout("Taxi1")
'Msgbox("Welcome to B4A test!", "")

Dim i As Int = 0

For i=0 To cur.RowCount-1
lstSuburbs.Add(cur.GetString("Suburb"))
cur.Position=cur.Position+1
Next

'Msgbox(cur.RowCount,"")

acetFrom.SetItems(lstSuburbs)
acetTo.SetItems(lstSuburbs)

End Sub

it crashed at the sql.Initialize - this works in debug mode but not in release mode
 

Douglas Farias

Expert
Licensed User
Longtime User
B4X:
AddPermission(android.permission.WRITE_EXTERNAL_STORAGE)
try add at manifest
 
Upvote 0

eps

Expert
Licensed User
Longtime User
code tags nag aside...

You can always enable the logging in Release Mode, connect using the B4A Bridge and then use logging to see what errors are raised.

Use the pre-processor #BridgeLogger: True
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…