Converts an absolute Unit value to the specified measurement units
(this overload cannot convert to pixels).
Namespace:
C1.C1PreviewAssembly: C1.C1Report.2 (in C1.C1Report.2.dll)
Syntax
C# |
---|
public double ConvertUnit( Unit source, UnitTypeEnum destUnitType ) |
Visual Basic |
---|
Public Function ConvertUnit ( _ source As Unit, _ destUnitType As UnitTypeEnum _ ) As Double |
Parameters
- source
- Type: C1.C1Preview..::..Unit
The source Unit value to convert (must be an absolute value).
- destUnitType
- Type: C1.C1Preview..::..UnitTypeEnum
The destination unit type (UnitTypeEnum; cannot be Pixel).
Return Value
A double representing the source value expressed in destUnitType units.Remarks
The source must be an absolute value, such as "5mm", "1.5in", "8" and so on. The source cannot be an expression (such as "prev.width" or "prev.height*2+2mm").
The destination units cannot be Pixel. To convert to pixels, use ConvertUnit(Unit, UnitTypeEnum, Single) instead.