An "Error: Unable to write to destination" Error Occurs When Laserfiche Forms Attempts To Save To Laserfiche.

April 19, 2013 | KB: 1013193
Laserfiche Forms 9.0

Summary

When Forms is configured to Save to Laserfiche, the form submission process may not successfully create image pages in Laserfiche for the submitted form. The Windows Event Log may contain error messages similar to the following:

    Loading pages (1/6)
    [> ] 0%
    [=> ] 2%
    [===> ] 5%
    [====> ] 7%
    [======> ] 10%
    [===================> ] 32%
    Warning: Failed loading page E:\Program (ignored)
    [=================================> ] 55%
    Warning: Failed loading page http: (ignored)
    [=================================> ] 55%
    [==================================> ] 57%
    [===================================> ] 59%
    [====================================> ] 60%
    [====================================> ] 60%
    [====================================> ] 61%
    [=====================================> ] 62%
    [=====================================> ] 62%
    [=====================================> ] 63%
    [======================================> ] 64%
    [======================================> ] 64%
    [=======================================> ] 65%
    [=======================================> ] 66%
    [========================================> ] 67%
    [========================================> ] 68%
    [==========================================> ] 71%
    [===========================================> ] 73%
    [============================================> ] 74%
    [==============================================> ] 77%
    [============================================================] 100%
    Warning: Failed loading page http://files (ignored)
    QPainter::begin(): Returned false
    Error: Unable to write to destination

    Stack trace: at Laserfiche.Forms.Routing.HtmlToPdfConverter.GeneratePrint()
    at Laserfiche.Forms.Routing.SaveToLFService.GetPrintFromHtmlForm()
    at Laserfiche.Forms.Routing.SaveToLFService.GetPDFAndSaveToLF()

Cause

Laserfiche Forms is unable to retrieve the path to the temporary folder location. This issue can occur in two situations:

  • Laserfiche Forms is not installed in the default path of "C:\Program Files\Laserfiche\Laserfiche Forms" or "'C:\Program Files (x86)\Laserfiche\Laserfiche Forms."
  • The Windows NTFS 8.3 naming convention option is disabled.

Workaround 1

Uninstall and reinstall Laserfiche Forms in the default location on the C drive.

Workaround 2

Use the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem\NtfsDisable8dot3NameCreation registry value to allow NTFS to generate a short name in the 8.3 naming convention.

Warning: Incorrectly editing the registry may adversely affect your system. Before you edit the registry, make sure you have a backup and understand how to restore it if a problem occurs.

  1. Load the Windows Registry Editor.
  2. Expand HKEY_LOCAL_MACHINE.
  3. Expand SYSTEM.
  4. Expand CurrentControlSet.
  5. Expand Control.
  6. Select FileSystem.
  7. Double-click the NtfsDisable8dot3NameCreation DWORD value and set the value to 0.
  8. Reinstall Laserfiche Forms.

For more information on the NtfsDisable8dot3NameCreation registry value, see the following Microsoft TechNet article.

http://technet.microsoft.com/en-us/library/cc778996(v=ws.10).aspx