Skip to main content
Kofax

File not Found error importing emails and attachments with long file names

11557

QAID # 11557 Published

Question / Problem:

How can a file not found error be avoided while using Kofax Capture Import Connector - Email and long file names?

Answer / Solution:

The Underlying Limitation

The underlying limit for a path in ImageControls is 128 characters. If an emailed file has a name long enough that the full path to it exceeds this limit, importing it will result in a file not found error. Windows short names are used for directories (e.g., "Documents and Settings" = DOCUME~1).

The Specific Manifestation

When using Import Connector - Email, the files are first brought into the MailStore and then imported from there.

The default MailStore location is

C:\Documents and Settings\All Users\Application Data\Kofax\Capture\Local\MailStore\

which is

C:\DOCUME~1\ALLUSE~1\APPLIC~1\Kofax\Capture\Local\MAILST~1\

in short name format.

There are then an additional two levels of GUID folders added to this path (such as "3AC96A~1\9390DC~1\"). This brings the default MailStore path to 77 characters, meaning that a safe filename must be 51 characters or less including the extension.

The Workaround

To be able to use longer file names the MailStore can be changed to a shorter path. This can be done by adding an attribute to the ACEIConfiguration node of CaptureSV\ACEI\ACEIConfig.xml.

DownloadFolder

The default value is an empty string ("") which indicates that email will be stored in the default MailStore folder location. You can specify a different folder by replacing the empty string with a valid Windows folder path (UNC paths are supported.)

Example ACEIConfig.xml file

<?xml version="1.0"?>
<!DOCTYPE ACEIConfiguration PUBLIC "ACEIConfig.dtd" "ACEIConfig.dtd"[]>
<ACEIConfiguration AscentCaptureUser="" AscentCapturePassword="" NotifyAdmin="True" NotifySender="False"
AdministratorEmail="TestUser@TestDomain.com" MailServer="999.99.9.999" MailPort="25"
RequireAuthentication="False" MailAccount="" MailPassword="" UseSSL="False" EmailPerBatch="3"
DataSetByUser="True" NotifyAdminWithOriginalEmail="False"
DownloadFolder="\\MyComputer\CaptureSV\ACEI\MailDownload" EmailsPerDownload="100">
<ACEIMailboxes>
    <ACEIMailbox MailAccount="TestUser@TestDomain.com" MailProtocol="POP3" MailboxName="My test mailbox"
        UseSSL="False" MailServer="999.99.9.999" TimeInterval="60" MailPassword="JWn/dLVvSWFsec03"
        MailPort="110" MailboxGUID="204b0361-5334-407a-9c09-b6125c19a126">
        <BatchClass DocumentClassName="Catalog Orders" BatchClassName="Order Forms"
            FormTypeName="Northwest Order Forms">
            <IndexFields/>
        </BatchClass>
        <ACEIMailbox>
    </ACEIMailboxes>
</ACEIConfiguration>

Applies to:

Product Version Category
CAPTURE 8.0 Import Connector - Email