'to String Open "c:\ttt.bmp" For Binary Access Read As #1 ReDim abyte(LOF(1) - 1) As Byte Get #1, , abyte Close #1 Dim str1 As String str1 = abyte Erase abyte
'from String Dim abyte2() As Byte abyte2 = str1 Open "c:\ttt2.bmp" For Binary Access Write As #2 Put #2, , abyte2 Close #2
Open "c:\ttt.bmp" For Binary Access Read As #1
ReDim abyte(LOF(1) - 1) As Byte
Get #1, , abyte
Close #1
Dim str1 As String
str1 = abyte
Erase abyte
'from String
Dim abyte2() As Byte
abyte2 = str1
Open "c:\ttt2.bmp" For Binary Access Write As #2
Put #2, , abyte2
Close #2