[CLOSED] Can't get email header (subject) from icloud using synapse lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- pcurtis · 2021-10-20 12:04 I use this to connect to iclouds imap server, 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.CheckMail(aUsername : String; aPassword : String; aServer : String);var  imap : TIMAPSend;   MimeMess : TMimeMess;begin  Application.ProcessMessages;  imap := TIMAPSend.create;  MimeMess := TMimeMess.Create;  MimeMess.Header.CharsetCode := UTF_8;   imap.FullSSL := true;  imap.Username:=aUsername;  imap.Password:=aPassword;  imap.TargetHost:=aServer;  imap.TargetPort := '993';  imap.Timeout := 2000;   if imap.login then    begin      imap.SelectFolder('INBOX');        imap.FetchMess(20, MimeMess.Lines);  //yes the message exists and has a subject                MimeMess.DecodeMessage;        ShowMessage(MimeMess.Header.Subject);      ..........  The login is OK, but fetching a mail always returns empty headers. Any ideas? ---------------------------------------------------------------------- pcurtis · 2021-10-20 15:58 Don't know what I've done but it works now Ok, fetchmessage only gets the body on icloud, on other servers it gets headers + body