GetAvailableAttrs Method (ItemClassAttr)
- Last UpdatedNov 06, 2025
- 2 minute read
'Declaration
Public Shared Function GetAvailableAttrs( _
ByVal itemClassId As String, _
ByVal userId As String _
) As DataSet
'Usage
Dim itemClassId As String
Dim userId As String
Dim value As DataSet
value = ItemClassAttr.GetAvailableAttrs(itemClassId, userId)
public static DataSet GetAvailableAttrs(
string itemClassId,
string userId
)
Parameters
- itemClassId
- Required. Holds the ID of the item class for which a list of available attributes is being requested.
- userId
- Required. Holds the ID of the user requesting the list of available attributes.
Return Value
Returns a DataSet that contains all the records in the Attr table that satisfy the specified filters. If no matching records are found, an empty DataSet is returned.
The columns of the returned DataSet are described below.
|
Column Name |
Description |
|---|---|
|
attr_id |
An integer that is the attribute ID. |
|
predefined |
A Boolean that is a flag that specifies whether the attribute has a defined set of values in the Attr_Set table. |
|
data_type |
An integer that is an enumeration that indicates the data type of the attribute, from the data_type column of the Attr table linked by the attr_id. 0 = string (<= 80 characters; the default data type) 1 = drop-down list of values defined in the Attr_Set table 2 = integer 3 = currency 4 = color 5 = datetime 6 = floating point number 7 = percent 8 = check box 9 = non-editable 10 = time of day 11 = item reason (only if attr_grp = 3) 12 = long string (> 80 characters) |
|
attr_desc |
A string that is the description of the attribute, from the attr_desc column of the Attr table link by the attr_id. |
|
attr_grp |
An integer that is an enumeration that indicates the group to which the attribute belongs, from the Attr table. 1 = Items 2 = Entities 3 = Lots 4 = Item Classes 5 = Jobs 6 = WO 7 = Operations 8 = Processes 9 = Sublot 10 = Samples 11 = Results 12 = Lines 13 = Shifts |
|
filter |
A string that is the situation to which this attribute applies. |
|
entry_type |
An enumeration that indicates the type of entry to allow for this attribute, from the entry_type column in the Attr table linked by the attr_id. 0 = value only (the default) 1 = notes only 2 = value and notes |
This method returns a DataSet of available attributes from the Attr table whose attribute group belongs to item class (=4). The available list of item class attributes are retrieved based on the following criteria:
- The attribute must belong to item class group (attr_grp = 4).
- If the attribute has a certification attached to it, the supplied user must have this certification, at a level that is equal to or greater than the required certification level, or no users may have this certification.
- All attributes that are currently assigned to the supplied item class are excluded from the DataSet.