INFO: StartPage/EndPage Resets Printer DC Attributes in Windows 95

ID: Q125696

4.00 WINDOWS kbprint
The information in this article applies to:
  • Microsoft Win32 Application Programming Interface (API), used with:
    • Microsoft Windows 95


SUMMARY

When you print under Windows version 3.x, the printer device context attributes, including things like mapping modes, current pen, current brush, and so on, are reset to their defaults for the device when the end of a page is reached. The escapes NEWFRAME and NEXTBAND and the API EndPage all cause the printer device context to be reset.

When you print under Windows NT version 3.x, the printer device context attributes are not reset during a print job.

When you print under Windows 95, the point at which the printer device context is reset to the default attributes depends on what version the executable was marked as. For executables marked as 3.x, the printer device context will be reset when EndPage is called. For executables marked as 4.0, the printer device context will be reset when StartPage is called. This applies to both 16-bit-based and Win32-based executables running under Windows 95.

A 16-bit-based executable's version can be set by using the Resource compiler's /xx switch where xx is 30, 31, or 40. A Win32-based executable's version can be set by using the /SUBSYSTEM:windows,x.x linker switch.

Additional query words: 95

Keywords : kbSDKWin32 kbWinOS95 kbDSupport
Version : winnt:
Platform : winnt
Issue type : kbinfo


Last Reviewed: July 7, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.