Lumi mail pop3

  • Thread starter Thread starter nevin
  • Start date Start date
N

nevin

Hello all,

if anyone has used the lumisoft controls and managed to get an attachment
downloaded, extracted, decoded (from base64) and saved to disk/stream can
they please show me how they did it?
Seems easy to get attachments into a message but not out.

Thanks
nev.
 
Hi,

There is sample application:

http://www.lumisoft.ee/lswww/download/downloads/Examples/

Basically message is retrieved as byte[] data, you need to pass data to
MimeParser class.
You get attachments MimeParser.Attachments.

// Connect and fill full message info
using(POP3_Client c = new POP3_Client()){
c.Connect(m_pServer.Text,110);
c.Authenticate(m_pUserName.Text,m_pPassword.Text,true);

MimeParser m = new
MimeParser(c.GetMessage((int)m_pMessagesList.SelectedItems[0].Tag));

// Add attachments
foreach(MimeEntry ent in m.Attachments){
// Your attachmnet is there
byte[] attachmentData = ent.Data;
}
}
 
Back
Top