メールの件名と送信者をリストボックスに表示するために、chilkat コンポーネントAvailable Hereを使用しています。
前もって感謝します
ここまでのコード
// Set the GMail account POP3 properties.
mailman.MailHost = "pop.gmail.com";
mailman.PopUsername = "**********";
mailman.PopPassword = "**********";
mailman.PopSsl = true;
mailman.MailPort = 995;
Chilkat.EmailBundle bundle;
// Read mail headers and one line of the body.
// To get the full emails, call CopyMail instead (no arguments)
bundle = mailman.GetEmail(1);
if (bundle == null)
{
MessageBox.Show(mailman.LastErrorText);
return;
}
int i;
Chilkat.Email email;
for (i = 0; i <= bundle.MessageCount - 1; i++)
{
email = bundle.GetEmail(i);
// Display the From email address and the subject.
listBox1.Items.Add( email.From + "\r\n");
listBox1.Refresh();
listBox2.Items.Add( email.Subject + "\r\n" + "\r\n");
listBox2.Refresh();
textBox1.Text += email.Body + "\r\n" + "\r\n";
}
}
}