eneam / mboxviewer

A small but powerfull app for viewing MBOX files
Other
430 stars 24 forks source link

Export/print attachments in line with emails in PDF #19

Closed arccpa closed 2 years ago

arccpa commented 2 years ago

Hello - I am trying to export an mbox file to PDF, and I'd like all the attachments to the emails to also print into the PDF. The current output has a link in the PDF, but I cannot tell if the target file is embedded in the PDF (I do not think it is). Can anyone tell me if they've accomplished same, or it isn't possible? Thanks

zigm commented 2 years ago

When you print/export to PDF, only so called inline attachments embedded into text are printed. So called true (or non-inline) attachments you must print yourself to PDF using appropriate applications such as Word, Excel, PowerPoint, etc. MBox Viewer doesn't have ability to print PowerPoint, etc documents to PDF. You can access attachment documents as follows:

  1. Print to HTML. Links to attachments are working properly. Unfortunately links to attachments in PDF document don't work. I was not able to resolve this issue yet. By default only links to true attachments are listed. To list all attachments, select "File->Attachment Config" and set " Show All Attachments".
  2. or, Left double click on an email to open Folder with all attachments

Once you printed all attachments to PDF, you must use separate application to merge all PDF files. You can use free PDFBox application to merge all pdf files. See User Guide how to do that. You should be able to leverage scripts/PDFMerge-pdfbox.cmd batch file to merge files. You must make small modifications to the script.

In the future I will consider to append to the email PDF all attachments that Edge or Chrome browsers can open.

Let me know if the above information was helpful.

Thanks, Zbigniew

arccpa commented 2 years ago

Hi Zbigniew - Thanks so much for this careful response, I really appreciate you taking the time. In my case, I realized I also have the option to export to PST (the source is google vault), and I ended up using that and the acrobat plugin - this doesn't print the attachments to the PDF, but it does attach them and store them in a single file. If this comes up for anyone else working with vault who has the option of PST (or if Mbox can convert to PST), this may be useful.

On Sat, Dec 4, 2021 at 6:47 PM zigm @.***> wrote:

When you print/export to PDF, only so called inline attachments embedded into text are printed. So called true (or non-inline) attachments you must print yourself to PDF using appropriate applications such as Word, Excel, PowerPoint, etc. MBox Viewer doesn't have ability to print PowerPoint, etc documents to PDF. You can access attachment documents as follows:

  1. Print to HTML. Links to attachments are working properly. Unfortunately links to attachments in PDF document don't work. I was not able to resolve this issue yet. By default only links to true attachments are listed. To list all attachments, select "File->Attachment Config" and set " Show All Attachments".
  2. or, Left double click on an email to open Folder with all attachments

Once you printed all attachments to PDF, you must use separate application to merge all PDF files. You can use free PDFBox application to merge all pdf files. See User Guide how to do that. You should be able to leverage scripts/PDFMerge-pdfbox.cmd batch file to merge files. You must make small modifications to the script.

In the future I will consider to append to the email PDF all attachments that Edge or Chrome browsers can open.

Let me know if the above information was helpful.

Thanks, Zbigniew

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/eneam/mboxviewer/issues/19#issuecomment-986143587, or unsubscribe https://github.com/notifications/unsubscribe-auth/AWY7ITHRUWRVJCFLASRR2JDUPKZBNANCNFSM5JL7HD6A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

zigm commented 2 years ago

Thanks for letting me know how you solved the issue. There are many ways to address requirement you have. Another approach is to use Adobe Acrobat (or similar tools) to attach attachments in the native format to printed/exported email in PDF format or to convert attachments into PDF and merge as a single PDF. Single PDF has some advantages such searching across the email and all email's attachments. MBox Viewer doesn't have similar capability. It relies on Edge or Chrome to convert HTML files to PDF. MBox Viewer generates emails in PDF format and all attachments in the native format that can later be combined into a single file using Adobe Acrobat or similar tools. thanks, Zbigniew

zigm commented 2 years ago

Closing the ticket. Potential solution similar to to reported PST based solution is to export a given mail as eml mail archive file. Eml file contains the mail message and all attachments in a single file. Eml mail file can be viewed by MBox Viewer, Thunderbird and many other known mail viewers. Select "File->Options->Export EML -> Yes" to enable export of emails to eml files. Left double click the email to open folder with eml file and other mail related files.