Print Microsoft Word Documents
    • 18 Jun 2024
    • 2 Minutes to read
    • Contributors
    • PDF

    Print Microsoft Word Documents

    • PDF

    Article summary

    This article provides a solution for automatically printing Microsoft ® Word documents stored in JobData or as attachments to JobData.

    Word Document Stored in JobData

    A Word document stored in JobData can be sent to the Print Output module as raw data. The Word file can (as an example) be received by a File Input module or retrieved via a Web Service, File Retriever, or Database module.

    A list of JobInfos must be defined for the Print Output module to enable the printing of Word documents stored in JobData.

    JobInfo

    Description

    Example

    JobData

    Binary Word Data

    [Binary]

    PrintMimetype

    Mimetype for Word file

    application/MSWord

    Word Document as an Attachment

    Word documents can also be stored as attachments to JobData.

    Retrieve one or several Word documents via file access in JavaScript, the Database module, or File Retriever module (file, FTP, or HTTP) and insert them as print attachments.

    A list of JobInfos must be defined for the Print Output module to enable the printing of Word documents attached to JobData:

    JobInfo

    Description

    Example

    PrintAttachment[index]

    Binary Word Data

    [Binary]

    PrintAttachmentMimetype[index]

    Mimetype for Word file

    application/MSWord

    Additional Information

    From Windows 7 ® and Windows Server 2008 ®, the following folders must exist to enable auto-printing of Word documents:

    C:\Windows\System32\config\systemprofile\Desktop

    C:\Windows\SysWOW64\config\systemprofile\Desktop (x64 OS only)

    If the Desktop folders do not exist, you will receive the following error message in the Lasernet log, and MS ® Word will not be able to print the document:

    Error

    Could not print msword attachment: Unsupported variant type! [DispatchCaller::from_variant<IDispatch>]

    Ensure you have the necessary user rights in Windows ® to add the Desktop folders.

    Modules Required

    Printer Output

    The solution requires Microsoft ® Word 2010 or newer to be installed on the same computer as Lasernet for successfully printing Word documents.

    We recommend turning off any functionality in MS ® Word that can cause MS ® Word to pop with a dialog that will require user interaction.

    The solution has only been verified with Microsoft ® Word 2010 and 2013 (64-bit) on the following operating systems:

    • Windows 7 and 8.1 (64 bit)

    • Windows 2008 Server (64 bit)

    Printer Profiles are not supported in Lasernet when printing Word documents via an external application like Microsoft ® Word.

    Ensure that the Lasernet Service has the required user rights to enable Microsoft ® Word to print to the selected Windows ® print queue, defined in the Printer Output settings.

    Info

    Using Microsoft ® Word for printing Word documents in the background, by the Lasernet service, is an undocumented feature. Formpipe Software is not responsible for a possible future version of the OS ® or Microsoft ® Word causing the functionality to stop working.


    What's Next
    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.