Android Question Copy some files from DirAssets to DirInternal

Douwe Siegersma

Member
Licensed User
Longtime User
I want to copy some files from DirAssets to DirInternal. Only files containing "old"'.
I always get a 'File not found' error.

B4X:
        Dim HL As List
        Dim F As String
        
        HL = File.ListFiles(File.DirAssets)
        For i = 0 To HL.Size-1
            F = HL.Get(i)
            If F.Contains("old") Then
                File.Copy(File.DirAssets,F,File.DirInternal,F)
            End If
        Next

And I only want to copy this files when the app is installed. How do I do that?
 

DonManfred

Expert
Licensed User
Longtime User
Upvote 0
Top