Description
Returns number of millipoints for the specified measurement string, e.g. "10pt".
Note: the result depends on the 1/72 inch point global option (BigPoints="false" or BigPoints="true" in GlobalConfig).
Syntax
mValue = Units.ToVal(strMeasure) |
strMeasure
Required. A string expression, containing a valid GN4 measure, e.g. 10pt.
Use the decimal point to specify decimal parts of the measure, even if your locale assumes decimal comma.
Remarks
dim mValue = Units.ToVal("10pt")
Returns 10000 if BigPoints="false" in GlobalConfig, or 10040 if it's True.
dim mValue = Units.ToVal("10")
Returns millipoints for 10 default units. It returns 10000 if BigPoints="false" in GlobalConfig, or 10040 if it's True.
dim mValue = Units.ToVal("10mt")
Returns 0, as 10mt is an invalid measurement. Use CheckStr to exclude invalid measurement strings.
See also