Microsoft KB Archive/221200

= AddPrinter API Call Allows Invalid Data Type =

Article ID: 221200

Article Last Modified on 2/24/2007

-

APPLIES TO


 * Microsoft Windows NT Server 4.0, Terminal Server Edition Service Pack 4
 * 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 Workstation 4.0 Developer Edition
 * Microsoft Windows NT Workstation 4.0 Developer Edition

-



This article was previously published under Q221200





SYMPTOMS
When you use the AddPrinter API call to create printers programmatically, custom settings that you specify may not be used.



CAUSE
This behavior can occur if you add a data type that is not valid with other settings. For example, the EMF and Direct Printing settings are not compatible with each other. The validity of the API call is not checked by the operating system.



RESOLUTION
To verify settings that are valid for any data type:
 * 1) Click Start, point to Settings, and then click Printers.
 * 2) Create a new printer, or right-click a printer and then click Properties.
 * 3) Configure all the settings that you want to program and verify that the settings are available for the data type (such as RAW or EMF).



STATUS
This behavior is by design.

Keywords: kbprint kbprogramming kbprb KB221200

-

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

© Microsoft Corporation. All rights reserved.