SIToScaledString(Double, String, String, Double, Double) Method
Turns the given number of units into a textual representation with an appropriate unit scaling.
Namespace: Gemstone.UnitsAssembly: Gemstone.Common (in Gemstone.Common.dll) Version: 1.0.128 -- Release Build+d050cfc5563c89a1188cc3c6b2d417530856f490
public static string ToScaledString(
double totalUnits,
string format,
string unitName,
double minimumFactor = 1E-24,
double maximumFactor = 1E+24
)
Public Shared Function ToScaledString (
totalUnits As Double,
format As String,
unitName As String,
Optional minimumFactor As Double = 1E-24,
Optional maximumFactor As Double = 1E+24
) As String
public:
static String^ ToScaledString(
double totalUnits,
String^ format,
String^ unitName,
double minimumFactor = 1E-24,
double maximumFactor = 1E+24
)
Gemstone.Units.SI.ToScaledString = function(totalUnits, format, unitName, minimumFactor, maximumFactor);
- totalUnits Double
- Total units to represent textually.
- format String
- A numeric string format for scaled totalUnits.
- unitName String
- Name of unit display (e.g., you could use "m/h" for meters per hour).
- minimumFactor Double (Optional)
- Optional minimum SI factor. Defaults to Yocto.
- maximumFactor Double (Optional)
- Optional maximum SI factor. Defaults to Yotta.
StringA
String representation of the number of units.
Symbols array is used for displaying SI symbol prefix for
unitName.
ArgumentOutOfRangeException | minimumFactor or maximumFactor is not defined in Factors array. |