Pageflex Document Action API
Implicit Operator
Namespaces > Pageflex.Scripting > Measurement > Implicit(String)
Converts a string representing a measurement (such as "1.3cm") to a Measurement object.
Syntax
C# | Visual Basic | Managed C++ |
public static implicit operatorMeasurement ( string s )
Public Shared Widening Operator CType ( _ s As String _ ) As Measurement
UnsupportedOperator_ManagedCPlusPlus
Return Value
A Measurement representing the value specified by the given string.
Remarks
This implicit conversion allows writing code using measurement strings in place of numbers. For example, the statement:
sets the width of the shape to 4 centimeters via an implicit conversion to a Measurement object.
1shape.Width = "4cm";
Exceptions
Exception | Condition |
---|---|
InvalidMeasurementException | The specified string could not be converted to a Measurement. |
Assembly: PFScript Version: 8.0.7.1407 (Module: PFScript)