User Tools

Site Tools


api:dk11:delphi:giscsbase.tgis_csunits.asareal_double_boolean_string

TGIS_CSUnits.AsAreal method

DK11 for Delphi | GisCsBase.TGIS_CSUnits.AsAreal | Constructors | Methods | Properties

Convert units as areal to string representation with proper units symbol.

Available also on: .NET | Java | ActiveX | Python.

Syntax

// Delphi
public
  function AsAreal(
    const _value : Double;
    const _prec : Boolean;
    const _format : String
  ) : String;
// C++ Builder
public:
  UnicodeString AsAreal(
    const double _value,
    const bool _prec,
    const UnicodeString _format
  );

Parameters

Name Type Description
_value Double units in base metric
_prec Boolean if true then fixed decimal digits will be presented; if false then only significant digits (no trailing zeros) will be presented
_format String hint of how to present linear symbols: for example by providing 'sq. %s' linear symbols will be presented as '1 sq. km'

Result

Type Description
String Units converted to string.

Remarks

Linear units will be autoconverted to areal.
Units of returned string will be autoselected to choose the most adequate is unit is a type of TGIS_CSUnitsType.Auto.

References

2022/11/16 01:15

Page Tools