SQL Problem on Emulator

gadgetmonster

Active Member
Licensed User
Longtime User
Hi All

The firs thing my app does is check the existence of the db file and if it doesn't exist, it creates it. This works fine on my device but not on the emulator.

B4X:
File.MakeDir(File.DirRootExternal, "MyApp/database")
If File.Exists(File.DirRootExternal, "MyApp/database/MyApp.db") = False Then

dbSQL.Initialize(File.DirRootExternal, "MyApp/database/MyApp.db", True)
...
End if

It falls over on the Initialise line with 'Could not open database' exception.

Any ideas?
 

stevel05

Expert
Licensed User
Longtime User
Did you create an SD card for the emulator? You need to enter the required size when creating in the AVD.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…