Android Question Read file to binary

stephankuba

Member
Licensed User
Longtime User
Hi,

is it possible to read any file into binary? (Bits)
Because I want to change some bits and write it back to the file.
I saw the RandomAccessFile but there is only read byte.

Maybe someone has a code for this, because I don't realy understand the RandomAccessFile Library.

thank you.
 

stephankuba

Member
Licensed User
Longtime User
thank you for your fast answear.

I have some questin about this:

B4X:
Dim test As RandomAccessFile
Dim readf() As Byte

test.Initialize(File.DirRootExternal,"test.dat",False)
test.ReadBytes(readf(),????,???,???)

Msgbox(test,"test")

I want to get the hole file in the readf() array, what parameter must I choose?

thank you
 
Upvote 0
Top