Reputation: 317
In B4A (or just Visual Basic), I've created a directory:
Files.MakeDir(Files.DirInternal, "app_data)
However, when I try and read a file I get an error stating the directory/file doesn't exist:
Files.ReadString(Files.DirInternal & "/app_data", "text.txt")
Is there a different way in which I should go into the directory to read the file?
Upvotes: 0
Views: 906
Reputation: 1326
Creating new directory if no such directory exist
pth = "d:\user_login"
If Directory.Exists(pth) = False Then
Directory.CreateDirectory(pth) 'create a folder in the path is no such folder is existing
End If
Upvotes: 0