Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AF SDK Reference

AFDataCache.TrimData Method (AFAttribute, AFTime)

  • Last UpdatedNov 18, 2025
  • 2 minute read
AFDataCache.TrimData Method (AFAttribute, AFTime)
Trims any cached data for the AFAttribute at or before the specified AFTime.

Namespace:  OSIsoft.AF.Data
Assembly:  OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182

Syntax

public void TrimData(
	AFAttribute attribute,
	AFTime trimToTime
)
Public Sub TrimData ( 
	attribute As AFAttribute,
	trimToTime As AFTime
)

Dim instance As AFDataCache
Dim attribute As AFAttribute
Dim trimToTime As AFTime

instance.TrimData(attribute, trimToTime)
public:
void TrimData(
	AFAttribute^ attribute, 
	AFTime trimToTime
)
member TrimData : 
        attribute : AFAttribute * 
        trimToTime : AFTime -> unit 

Parameters

attribute
Type: OSIsoft.AF.AssetAFAttribute
The attribute to trim data for
trimToTime
Type: OSIsoft.AF.TimeAFTime
The time to trim up to. Any cached values at or before the specified time will be removed.

Exceptions

ExceptionCondition
ArgumentException The AFAttribute is null
KeyNotFoundException The AFAttribute has not been added to this AFDataCache.

Version Information

AFSDK

Supported in: 3.1.1, 3.1.0, 3.0.2, 3.0.1, 3.0.0, 2.10.11, 2.10.5, 2.10.0, 2.10, 2.9.5, 2.9, 2.8.5

See Also

In This Topic
Related Links
TitleResults for “How to create a CRG?”Also Available in