< Civ API Docs

UnitValueFormatterFormat(UnitType, DBObject, Double) Method

Formats a numeric value using the settings node resolved from sourceObject.

Namespace: Autodesk.Civil.Internal
Assembly: AeccDbMgd (in AeccDbMgd.dll) Version: 13.9.0.960
Syntax
public static string Format(
	UnitType unitType,
	DBObject sourceObject,
	double value
)

Parameters

unitType  UnitType
 
sourceObject  DBObject
 
value  Double
 

Return Value

String
Exceptions
ExceptionCondition
ArgumentException Thrown when sourceObject is null, does not expose a valid unmanaged pointer, or a valid settings node cannot be resolved.
InvalidEnumArgumentException Thrown when unitType is not a supported value.
Remarks

Settings-node resolution is based on the runtime type of sourceObject.

The settings node is resolved from sourceObject using the following order:

  • Objects of type Entity, CogoPoint, and PointGroup, including objects derived from these types, use their object-specific settings node.
  • Objects of type PointDescriptionKey, CogoPointCollection, and PointGroupCollection, including objects derived from these types, use point global settings.
  • If sourceObject already references a settings node object, that node is used directly.
  • Any other DBObject falls back to the drawing root settings node.
See Also