AFValue.Convert Method (UOM)
- Last UpdatedNov 18, 2025
- 2 minute read
- PI System
- AF SDK 2024 R2
- Developer
Namespace: OSIsoft.AF.Asset
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public AFValue Convert( UOM uom )
Public Function Convert ( uom As UOM ) As AFValue Dim instance As AFValue Dim uom As UOM Dim returnValue As AFValue returnValue = instance.Convert(uom)
public: AFValue^ Convert( UOM^ uom )
member Convert : uom : UOM -> AFValue
Parameters
- uom
- Type: OSIsoft.AF.UnitsOfMeasureUOM
The desired unit of measure for the new AFValue. The UOM specified must be of the same UOMClass as the current UOM for the value.
Return Value
Type: AFValueReturns a new AFValue in the specified UOM.
Remarks
If the current UOM for the value is not set, then no conversion takes place but the UOM of the returned value is set to the value of the uom parameter.
If the Value is an Array, then each item in the array will be converted to the specified uom.