Android Question Text File (.TXT) create, read write and append

hexatrik

Member
Licensed User
Longtime User
Hi,

How do I create, write, read and append text (.txt) file in B4A...
 

Tayfur

Well-Known Member
Licensed User
Longtime User
basiclly

B4X:
'****** for Write txt  or etc file for string******************
Dim mytext As String
mytext=" Erel Rulezz Erel Rulezzzzz Erel Rulezzzzzzz ...... "
File.WriteString(File.DirRootExternal,"sample.txt",mytext)
'****** for Read txt  or etc file for string******************
Dim myreadtext As String
myreadtext= File.ReadString(File.DirRootExternal,"sample.txt")
Log(myreadtext)
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…