andyedinborough / aenetmail

C# POP/IMAP Mail Client
370 stars 153 forks source link

body is null #78

Open gregwhite83 opened 12 years ago

gregwhite83 commented 12 years ago

bit of a noob on this but I have followed your example in the readme for version 1.6.0.0

using (var pop = new AE.Net.Mail.Pop3Client("xxxxxxxxx","test@xxxxxxxxx","xxxxxxxxx",110,false,false))

        for(var i = pop.GetMessageCount() - 1; i >= 0; i--){
  var msg = pop.GetMessage(i,false);
  Console.WriteLine(msg.Subject);
  Console.WriteLine(msg.From);
  Console.WriteLine(msg.Body);

}

body always returns empty any ideas? Subject and From are fine.

davidnjohnson commented 12 years ago

Try the BodyHtml property. It's hard to tell without documentation, but I think depending on the message type either Body or BodyHtml are filled.