Hi RamyMahrous,
thanks for your quick reply. I'm doing this at the request of my boss. From his explanation, the computer on which the pdf and xml files will be created have no connection to the internet, so the attachment should be stored in an .eml file to be somehow sent later. I don't know the details about how it's going to be sent later. All I know is that he wants the mail to be stored in .eml format. Does this help answer your question?