AFAttribute.FindNotificationAttributes Method (AFDatabase, String, String, AFCategory, AFElementTemplate, String, String, AFCategory, TypeCode, AFSortField, AFSortOrder, Int32)
- Last UpdatedNov 18, 2025
- 8 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 static AFAttributeList FindNotificationAttributes( AFDatabase database, string nameFilter, string descriptionFilter, AFCategory elemCategory, AFElementTemplate elemTemplate, string attrNameFilter, string attrDescriptionFilter, AFCategory attrCategory, TypeCode attrType, AFSortField sortField, AFSortOrder sortOrder, int maxCount )
Public Shared Function FindNotificationAttributes ( database As AFDatabase, nameFilter As String, descriptionFilter As String, elemCategory As AFCategory, elemTemplate As AFElementTemplate, attrNameFilter As String, attrDescriptionFilter As String, attrCategory As AFCategory, attrType As TypeCode, sortField As AFSortField, sortOrder As AFSortOrder, maxCount As Integer ) As AFAttributeList Dim database As AFDatabase Dim nameFilter As String Dim descriptionFilter As String Dim elemCategory As AFCategory Dim elemTemplate As AFElementTemplate Dim attrNameFilter As String Dim attrDescriptionFilter As String Dim attrCategory As AFCategory Dim attrType As TypeCode Dim sortField As AFSortField Dim sortOrder As AFSortOrder Dim maxCount As Integer Dim returnValue As AFAttributeList returnValue = AFAttribute.FindNotificationAttributes(database, nameFilter, descriptionFilter, elemCategory, elemTemplate, attrNameFilter, attrDescriptionFilter, attrCategory, attrType, sortField, sortOrder, maxCount)
public: static AFAttributeList^ FindNotificationAttributes( AFDatabase^ database, String^ nameFilter, String^ descriptionFilter, AFCategory^ elemCategory, AFElementTemplate^ elemTemplate, String^ attrNameFilter, String^ attrDescriptionFilter, AFCategory^ attrCategory, TypeCode attrType, AFSortField sortField, AFSortOrder sortOrder, int maxCount )
static member FindNotificationAttributes : database : AFDatabase * nameFilter : string * descriptionFilter : string * elemCategory : AFCategory * elemTemplate : AFElementTemplate * attrNameFilter : string * attrDescriptionFilter : string * attrCategory : AFCategory * attrType : TypeCode * sortField : AFSortField * sortOrder : AFSortOrder * maxCount : int -> AFAttributeList
Parameters
- database
- Type: OSIsoft.AFAFDatabase
The AFDatabase to search for the requested objects. - nameFilter
- Type: SystemString
The notification name filter string used for finding objects.The query string (or match pattern) can include regular characters and wildcard characters. Regular characters must match exactly the characters specified in the query string. Wildcard characters can be matched with arbitrary fragments of the query string. Wildcard characters can be escaped using the single backslash (\) character. Use a double backslash (\\) to match a single backslash. The syntax of the query string has the following rules:
- If or empty string, then everything will be matched.
- If no wildcards, then an exact match on the query string is performed.
- Wildcard * can be placed anywhere in the query string and matches zero or more characters.
- Wildcard ? can be placed anywhere in the query string and matches exactly one character.
- One character in a set of characters are matched by placing them within [ ]. For example, a[bc] would match 'ab' or 'ac', but it would not match 'ad' or 'abd'.
- One character in a set of characters are not matched by placing them within [! ]. For example, a[!bc] would match 'ad', but it would not match 'ab', 'ac', or 'abd'.
- A character in a range of characters from first to last are matched using the following syntax: [first - last]. For example, a[a-c] would match 'aa', 'ab', or 'ac', but it would not match 'ad' or 'abc'.
- descriptionFilter
- Type: SystemString
The element description filter string used for finding objects. Only the first 440 characters of the description will be searched. For servers older than 2.7, a NotSupportedException exception will be thrown if this parameter is specified.
The query string (or match pattern) can include regular characters and wildcard characters. Regular characters must match exactly the characters specified in the query string. Wildcard characters can be matched with arbitrary fragments of the query string. Wildcard characters can be escaped using the single backslash (\) character. Use a double backslash (\\) to match a single backslash. The syntax of the query string has the following rules:
- If or empty string, then everything will be matched.
- If no wildcards, then an exact match on the query string is performed.
- Wildcard * can be placed anywhere in the query string and matches zero or more characters.
- Wildcard ? can be placed anywhere in the query string and matches exactly one character.
- One character in a set of characters are matched by placing them within [ ]. For example, a[bc] would match 'ab' or 'ac', but it would not match 'ad' or 'abd'.
- One character in a set of characters are not matched by placing them within [! ]. For example, a[!bc] would match 'ad', but it would not match 'ab', 'ac', or 'abd'.
- A character in a range of characters from first to last are matched using the following syntax: [first - last]. For example, a[a-c] would match 'aa', 'ab', or 'ac', but it would not match 'ad' or 'abc'.
- elemCategory
- Type: OSIsoft.AFAFCategory
Specify that the owner of the returned attributes must have this category. To not filter by element category, then specify for this parameter. - elemTemplate
- Type: OSIsoft.AF.AssetAFElementTemplate
Specify that the owner of the returned attributes must have this template or a template derived from this template. To not filter by element template, then specify for this parameter. - attrNameFilter
- Type: SystemString
The attribute name filter string used for finding objects.
The query string (or match pattern) can include regular characters and wildcard characters. Regular characters must match exactly the characters specified in the query string. Wildcard characters can be matched with arbitrary fragments of the query string. Wildcard characters can be escaped using the single backslash (\) character. Use a double backslash (\\) to match a single backslash. The syntax of the query string has the following rules:
- If or empty string, then everything will be matched.
- If no wildcards, then an exact match on the query string is performed.
- Wildcard * can be placed anywhere in the query string and matches zero or more characters.
- Wildcard ? can be placed anywhere in the query string and matches exactly one character.
- One character in a set of characters are matched by placing them within [ ]. For example, a[bc] would match 'ab' or 'ac', but it would not match 'ad' or 'abd'.
- One character in a set of characters are not matched by placing them within [! ]. For example, a[!bc] would match 'ad', but it would not match 'ab', 'ac', or 'abd'.
- A character in a range of characters from first to last are matched using the following syntax: [first - last]. For example, a[a-c] would match 'aa', 'ab', or 'ac', but it would not match 'ad' or 'abc'.
- attrDescriptionFilter
- Type: SystemString
The attribute description filter string used for finding objects. Only the first 440 characters of the description will be searched. For servers older than 2.7, a NotSupportedException exception will be thrown if this parameter is specified.
The query string (or match pattern) can include regular characters and wildcard characters. Regular characters must match exactly the characters specified in the query string. Wildcard characters can be matched with arbitrary fragments of the query string. Wildcard characters can be escaped using the single backslash (\) character. Use a double backslash (\\) to match a single backslash. The syntax of the query string has the following rules:
- If or empty string, then everything will be matched.
- If no wildcards, then an exact match on the query string is performed.
- Wildcard * can be placed anywhere in the query string and matches zero or more characters.
- Wildcard ? can be placed anywhere in the query string and matches exactly one character.
- One character in a set of characters are matched by placing them within [ ]. For example, a[bc] would match 'ab' or 'ac', but it would not match 'ad' or 'abd'.
- One character in a set of characters are not matched by placing them within [! ]. For example, a[!bc] would match 'ad', but it would not match 'ab', 'ac', or 'abd'.
- A character in a range of characters from first to last are matched using the following syntax: [first - last]. For example, a[a-c] would match 'aa', 'ab', or 'ac', but it would not match 'ad' or 'abc'.
- attrCategory
- Type: OSIsoft.AFAFCategory
Specify that returned attributes must have this category. To not filter by attribute category, then specify for this parameter. - attrType
- Type: SystemTypeCode
Specify that returned attributes must have this Type. To not filter by attribute type, then specify Empty. If Object is specified, then attributes which do not have a type defined (displayed as Anything in PI System Explorer), will be returned, as well as types which cannot be described by a simpler type code, such as enumeration values, arrays, files, and references to other AF objects. - sortField
- Type: OSIsoft.AFAFSortField
The field or property of the object used to sort the returned collection. - sortOrder
- Type: OSIsoft.AFAFSortOrder
The order that the returned collection is sorted. - maxCount
- Type: SystemInt32
The maximum number of objects to be returned.
Return Value
Type: AFAttributeListReturns a collection containing the specified page of AFAttribute objects which match the specified filters.
Remarks
| Beginning with PI AF Server 2.6, only notification template information that is checked in to the permanent storage will be utilized in the search. |