Private Const BITSPIXEL = 12
Private Const LOGPIXELSX = 88
Private Declare Function ReleaseDC Lib "user32" (ByVal hwnd As Long, ByVal hDC As Long) As Long
Private Declare Function GetDeviceCaps Lib "Gdi32" (ByVal hDC As Long, ByVal Index As Long) As Long
Sub Main()
Dim hDC As Long
hDC = GetDC(0)
PointsPerPixel = 72 / GetDeviceCaps(hDC, LOGPIXELSX)
Call ReleaseDC(0, hDC)
End Sub
|