AFValue Constructor (Object, AFTime, UOM, AFValueStatus)
- Last UpdatedNov 18, 2025
- 2 minute read
- PI System
- AF SDK 2024 R2
- Developer
This is the constructor for an AFValue object which specifies
all the properties.
Namespace: OSIsoft.AF.Asset
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public AFValue( Object newValue, AFTime timestamp, UOM uom, AFValueStatus status )
Public Sub New ( newValue As Object, timestamp As AFTime, uom As UOM, status As AFValueStatus ) Dim newValue As Object Dim timestamp As AFTime Dim uom As UOM Dim status As AFValueStatus Dim instance As New AFValue(newValue, timestamp, uom, status)
public: AFValue( Object^ newValue, AFTime timestamp, UOM^ uom, AFValueStatus status )
new : newValue : Object * timestamp : AFTime * uom : UOM * status : AFValueStatus -> AFValue
Parameters
- newValue
- Type: SystemObject
The new value to be assigned to the Value property. - timestamp
- Type: OSIsoft.AF.TimeAFTime
The timestamp associated with the new value. - uom
- Type: OSIsoft.AF.UnitsOfMeasureUOM
The UOM of the specified value. - status
- Type: OSIsoft.AF.AssetAFValueStatus
The status which indicates whether the new value is a good or bad status, substituted, questionable, or annotated.
Exceptions
| Exception | Condition |
|---|---|
| InvalidCastException | This exception is thrown if the type of newValue does not support specifying a UOM. |
Remarks
All properties of the new value are set according to the specified parameters.