Indy9 Get Raw Email Header?

Does Indy9 have any way to get a specific raw email header (like "Subject" or "From") that still includes the transfer encoding (ie the DecodeHeader was not mangled in older Delphi versions since weak Unicode support), or will I have to manually parse the entire email header to extract this information?

0


source to share


2 answers


I solved the problem by calling IdMessage1.Headers.Values['Subject']

BEFORE the call IdMessage1.ProcessHeaders

gives different results than after.



0


source


The property TIdMessage.RawHeaders

is what you are looking for, for example:



Subject := IdMessage1.RawHeaders.Values['Subject'];

      

+1


source







All Articles