DimensionAttributeSetStorage.addItem Method [AX 2012]
Adds the specified dimension attribute and enumeration value to the set.
Syntax
public int addItem(
RecId _dimensionAttributeId,
HashKey _dimensionAttributeHashKey,
int _enumerationValue)
Run On
Called
Parameters
- _dimensionAttributeId
Type: RecId Extended Data Type
The dimension attribute ID of the dimension attribute to add.
- _dimensionAttributeHashKey
Type: HashKey Extended Data Type
- _enumerationValue
Type: int
The enumeration value of the dimension attribute to add.
Return Value
Type: int
The index of the value in the set.
Remarks
When the dimension attribute associated with the value is already in the set, that index will be updated to point to the new value and the same index will be returned. When the dimension attribute is not yet in the set, it will be added to the end and the index of the new value will be returned.
The set ordering and index are stable for a running instance of the DimensionAttributeSetStorage class, but may change if the instance is persisted and reloaded. Index access is provided as a simplification for programmatic interaction and is not persisted to the database.