Version

ToPixels(Single,Single,UnitOfMeasurement) Method

Converts the specified value into a pixel value at the specified resolution.
Syntax
'Declaration
 
Public Overloads Shared Function ToPixels( _
   ByVal value As Single, _
   ByVal dpi As Single, _
   ByVal unit As UnitOfMeasurement _
) As Integer
public static int ToPixels( 
   float value,
   float dpi,
   UnitOfMeasurement unit
)

Parameters

value
A value which represents a linear graphical quantity.
dpi
The resolution, expressed in dots per inch.
unit
A UnitOfMeasurement constant which defines the unit of measure in which the value is expressed.
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also