Android Question sqlite database file on SDCard

Binary01

Active Member
Licensed User
Longtime User
Hi,

I created a database app. It can access database from internal storage.
sample code is here:

'process global
Dim DBFileName As String : DBFileName = "sample.db3"
Dim DBFileDir As String : DBFileDir = File.DirDefaultExternal

'Activity_Create
If FirstTime Then
If File.Exists(File.DirDefaultExternal, DBFileName) = False Then
File.Copy(File.DirAssets, DBFileName, DBFileDir, DBFileName)
End If
SQL1.Initialize(DBFileDir, DBFileName, True)
End If

Now, I want to access database file on SD Card.
How?

Thanks.
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Upvote 0
Top