Reputation: 11
I used IdTCPClient1.IOHandler.Write(edit1.Text+crlf);
to send a text and, to receive, the code below is usd:
procedure TForm1.IdTCPServer1Execute(AContext: TIdContext);
begin
edit2.Text:=trim(AContext.Connection.IOHandler.readln(crlf));
edit3.Text:='1';
end;
Both are correct in pc to pc connection. but when I send the data from pc to my android based phone, the procedure TForm1.IdTCPServer1Execute
runs and AContext.Connection.IOHandler.readln(crlf)
caused to terminate the process of the procedure and no data would be catched.
No ereror was detected and other parts work fine.
how can I receive data (string or numbers) in android based systems?
Upvotes: 1
Views: 660
Reputation: 17
I had the same problem and I found the android version of my device is older than what I installed in my PC (SDK). Try your program with older version. termination of your program is because of it.
Upvotes: 1