Skip to main content

Jet Scheduler Sends Corrupt Attachments When Using SMTP

Symptom

When the Jet Scheduler is configured to use SMTP to send emails for a Jet report with a long filename that includes double-byte characters (e.g., à é î ö û) - as is common in Chinese, Japanese, Korean, Polish, Romanian, Ukrainian, etc. - the file attached to the recipient's email is not a valid PDF or Excel file or and has a cryptic name (often starting with "UTF").

Cause

The SMTP Attachment object in the Microsoft .NET Framework imposes a limitation on the length of the filename when the filename or path contains at least one double-byte character.  Each double-byte character shortens this limit by an additional character.

Workaround

There are two workarounds for this issue:

  1. If possible, do not use double-byte characters in the path or filenames of Jet Reports that need to be emailed through SMTP.
  2. Shorten the filename until it is short enough to fall within the limitation imposed.

Was this article helpful?

We're sorry to hear that.