PoΦet barev podporovan²ch tiskßrnou

Postup:
V modulu deklarujte:


Private Declare Function GetDeviceCaps Lib "gdi32" _
(ByVal hdc As Long, ByVal nIndex As Long) As Long 

Const DEV_BITSPERPIXEL = 12 
Const DEV_PLANES = 14 

Public Function NumberOfPrinterColours() 

   NumberOfPrinterColours = GetDeviceCaps(Printer.hdc, DEV_PLANES) _
     * 2 ^ GetDeviceCaps(Printer.hdc, DEV_BITSPERPIXEL) 

End Function

Volßnφ:
Barvy = NumberOfPrinterColours()

Zp∞t

Autor: The Bozena