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

AF SDK Reference

AFAttribute.FindAttribute Method (AFBaseElement, AFAttributeTemplate)

AFAttribute.FindAttribute Method (AFBaseElement, AFAttributeTemplate)

  • Last UpdatedNov 18, 2025
  • 2 minute read
AFAttribute.FindAttribute Method (AFBaseElement, AFAttributeTemplate)
Retrieves the AFAttribute object created from the specified AFAttributeTemplate.

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

Syntax

public static AFAttribute FindAttribute(
	AFBaseElement element,
	AFAttributeTemplate template
)
Public Shared Function FindAttribute ( 
	element As AFBaseElement,
	template As AFAttributeTemplate
) As AFAttribute

Dim element As AFBaseElement
Dim template As AFAttributeTemplate
Dim returnValue As AFAttribute

returnValue = AFAttribute.FindAttribute(element, 
	template)
public:
static AFAttribute^ FindAttribute(
	AFBaseElement^ element, 
	AFAttributeTemplate^ template
)
static member FindAttribute : 
        element : AFBaseElement * 
        template : AFAttributeTemplate -> AFAttribute 

Parameters

element
Type: OSIsoft.AF.AssetAFBaseElement
The AFBaseElement to search for the AFAttribute identified by the specified template parameter.
template
Type: OSIsoft.AF.AssetAFAttributeTemplate
The AFAttributeTemplate of the AFAttribute to search for in the specified element.

Return Value

Type: AFAttribute
Returns the AFAttribute identified by the template in the specified element.

Remarks

The AFAttribute of the specified element created from the specified AFAttributeTemplate is returned. This method will return attributes marked as IsHidden or IsExcluded.

Version Information

AFSDK


See Also

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