Microsoft KB Archive/244261

= PRB: Printer.Print May Use Different Fonts on Different Computers =

Article ID: 244261

Article Last Modified on 5/12/2003

-

APPLIES TO


 * Microsoft Visual Basic 5.0 Enterprise Edition
 * Microsoft Visual Basic 6.0 Enterprise Edition
 * Microsoft Visual Basic 5.0 Professional Edition
 * Microsoft Visual Basic 6.0 Professional Edition
 * Microsoft Visual Basic 5.0 Learning Edition
 * Microsoft Visual Basic 6.0 Learning Edition

-



This article was previously published under Q244261



SYMPTOMS
Using Printer.Print without first setting Printer.FontName and Printer.FontSize may produce a printout in a different font when the same application is used on different computers or with different printers.



CAUSE
If you use Printer.Print without first setting Printer.FontName and Printer.FontSize, the operating system selects a font for you based on numerous parameters, including which fonts are installed and the characteristics of the output device.



RESOLUTION
Explicitly set Printer.FontName and Printer.FontSize before printing.



STATUS
This behavior is by design.



MORE INFORMATION
If you select an unavailable font, the operating system uses font substitution to select a font for you. To avoid this, check the Printer.Fonts property, which returns an array of all fonts that are supported for the current printer. See online Help for details.

