I try to send file to other phone using bluetooth ,the problem is nothing is send , i am able to detected device and connect to it but no files send
[ code ]
Sub Serial1_Connected (Success As Boolean)
If Success = False Then
Log(LastException.Message)
ToastMessageShow("Error connecting: " & lastException.Message, True)
Else
File.WriteString(File.DirRootExternal, "Fatwa.txt",Module1.TxtForSend)
Dim In As InputStream
In = File.OpenInput(File.DirRootExternal, "Fatwa.txt")
Dim out As OutputStream
out=Serial1.OutputStream
out.InitializeToBytesArray(1000)
File.Copy2(In, out)
Dim data() As Byte
data = out.ToBytesArray
out.WriteBytes(data ,0,data.Length)
out.Flush
End If
[ /code ]
need help to solve this issue ,thank you
[ code ]
Sub Serial1_Connected (Success As Boolean)
If Success = False Then
Log(LastException.Message)
ToastMessageShow("Error connecting: " & lastException.Message, True)
Else
File.WriteString(File.DirRootExternal, "Fatwa.txt",Module1.TxtForSend)
Dim In As InputStream
In = File.OpenInput(File.DirRootExternal, "Fatwa.txt")
Dim out As OutputStream
out=Serial1.OutputStream
out.InitializeToBytesArray(1000)
File.Copy2(In, out)
Dim data() As Byte
data = out.ToBytesArray
out.WriteBytes(data ,0,data.Length)
out.Flush
End If
[ /code ]
need help to solve this issue ,thank you
Last edited: