Raphaël Désalbres
Guest
|
Posted:
Wed Nov 23, 2005 5:58 pm Post subject:
parse eml file attachment |
|
|
Hello, everybody,
I am facing the following problem: I need to open an .eml file, parse it to
get the attachment (which is a csv file) , but I don't know how.
Some people said the problem could be solved with Regex..
If someone could send me a code exerpt in C#, I would be very grateful...
Thanks very much,
Raphaël Désalbres
|
|
Raphaël Désalbres
Guest
|
Posted:
Wed Nov 23, 2005 5:58 pm Post subject:
Re: parse eml file attachment |
|
|
Hello,
I just found how...
CDO.DropDirectory iDropDir=new CDO.DropDirectoryClass();
CDO.IMessages iMsgs;
iMsgs = iDropDir.GetMessages("c:\\inetpub\\mailroot\\drop");
foreach(CDO.Message msg in iMsgs)
{
if(msg.Attachments.Count==1)
{
msg.Attachments[1].SaveToFile(@"C:\att.xml");
}
}
Thanks,
Raphaël....
"Raphaël Désalbres" <raphael@desalbres.com> escreveu na mensagem
news:OO1CqKD8FHA.4012@TK2MSFTNGP14.phx.gbl...
| Quote: | Hello, everybody,
I am facing the following problem: I need to open an .eml file, parse it
to get the attachment (which is a csv file) , but I don't know how.
Some people said the problem could be solved with Regex..
If someone could send me a code exerpt in C#, I would be very grateful...
Thanks very much,
Raphaël Désalbres
|
|
|