Click or drag to resize

MathString Class

Provides functions to convert between numbers and text strings, including formatting as fractions.
Inheritance Hierarchy
SystemObject
  Autodesk.iLogic.RuntimeMathString

Namespace:  Autodesk.iLogic.Runtime
Assembly:  Autodesk.iLogic.Runtime (in Autodesk.iLogic.Runtime.dll) Version: 23.0
Syntax
Public NotInheritable Class MathString

The MathString type exposes the following members.

Methods
  NameDescription
Public methodStatic memberCDblAny
Like the standard CDbl function, this converts a string to a double-precision number. But unlike CDbl, this will work on a string that uses either "." or "," as the decimal separator.
Public methodStatic memberFormatAsFraction(Double)
Formats a number as a fraction for inch measurements, with denominator as power of 2 (up to maximum of 128). Return a fraction, or number and fraction (e.g. 3 5/8), or decimal number if the input is not a power of 2 fraction (within 0.0000001)
Public methodStatic memberFormatAsFraction(Double, Int32)
Formats a number as a fraction for inch measurements, with denominator as power of 2 (up to maximum of 128). Return a fraction, or number and fraction (e.g. 3 5/8), or decimal number if the input is not a power of 2 fraction (within 0.0000001)
Public methodStatic memberRoundToFraction
Formats a numeric value as a text string, in fraction form to represent inch measurements. Returns a fraction(for example, "1/2"), or a number and fraction(for example, "3 5/8").
Top
See Also