Microsoft KB Archive/252663

= WritePrinter API Call Does Not Work When You Print to an LPR Printer =

Article ID: 252663

Article Last Modified on 11/1/2006

-

APPLIES TO


 * Microsoft Windows NT Server 4.0 Standard Edition
 * Microsoft Windows NT 4.0 Service Pack 6
 * Microsoft Windows NT 4.0 Service Pack 6a
 * Microsoft Windows NT Workstation 4.0 Developer Edition
 * Microsoft Windows NT Workstation 4.0 Developer Edition
 * Microsoft Windows NT Workstation 4.0 Developer Edition
 * Microsoft Windows NT Server 4.0 Enterprise Edition
 * Microsoft Windows NT 4.0 Service Pack 6
 * Microsoft Windows NT 4.0 Service Pack 6a

-



This article was previously published under Q252663



SYMPTOMS
When you try to print to an LPR printer, the WritePrinter application programming interface (API) may not work when the program you are using calls the API. The GetLastError API may return the following error message:

ERROR_INSUFFICIENT_BUFFER



CAUSE
This issue can occur if the status of the print job changes between the time the WritePrinter API requests the size needed for the status and the time the WritePrinter API requests the status from the spooler.



RESOLUTION
To resolve this issue, change the printer settings from the Start print immediately option to the Start printing after the last page is spooled option.

Keywords: kbprb KB252663

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.