Posting XML SOAP Envelope problem lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- Narki · 2022-12-24 14:15 Hello, This is my first post so "Hello" to everybody. I'm struggling with application "client side" to communicate with service. Requirement for that type of communication is to use XML Soap Envelope. I'm trying to use TFPHTTPClient for that. I prepare Form to see response from serwer but something is missing. When I send a request I receive error "Stream read error" On Form I put Button and Memo1 for displaing XML code and Memo2 for answear. Interesting is when I copy code from memo1 and paste into SoapUI everything is OK My code is: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i procedure TForm1.Button2Click(Sender: TObject);    var      FPHTTPClient: TFPHTTPClient;      SL: TStringList;      Str: String;     begin      FPHTTPClient := TFPHTTPClient.Create(nil);      try        FPHTTPClient.AllowRedirect := True;        FPHTTPClient.KeepConnection:=True;        FPHTTPClient.AddHeader('Content- Type','application/soap+xml;charset=utf-8');        FPHTTPClient.AddHeader('User-Agent','Apache-HttpClient/4.5.5 (Java/16.0.1)');          SL := TStringList.Create;         try        SL.Add(' ');          SL.Add('');          SL.Add(' https://wyszukiwarkaregontest.stat.gov.pl/wsBIR/UslugaBIRzewnP ubl.svc');          SL.Add('http://CIS/BIR/PUBL/2 014/07/IUslugaBIRzewnPubl/Zaloguj');          SL.Add('');          SL.Add('');          SL.Add('');          SL.Add('abcde12 345abcde12345');          SL.Add('');          SL.Add('');          SL.Add('');       Memo1.Lines.BeginUpdate;    Memo1.Lines := SL;    Memo1.Lines.EndUpdate;          try             Str:=FPHTTPClient.FormPost('https://wyszukiwarkaregontest.stat.gov.pl/ wsBIR/UslugaBIRzewnPubl.svc',SL);                        //ShowMessage(Str);     Memo2.text := Str;           except          on E: exception do              ShowMessage(E.Message);          end;        finally          SL.Free;        end;      finally        FPHTTPClient.Free;      end;    end;