Click or drag to resize

AttributeDatabaseExtensionsFindOrAddAttributeValue Method (IAttributeDatabase, UInt32, DataDimensions, Boolean)

Find or add an attribute value.

If an attribute value with the specified id already exists, then it's returned. If an attribute value with the specified id does not exist, then a new attribute value is created.

Namespace:  Demo3D.PLC.Comms.AttrDb
Assembly:  PLC (in PLC.dll) Version: 15.0.2.11458
Syntax
C#
public static AttributeValue FindOrAddAttributeValue(
	this IAttributeDatabase attrDb,
	uint attributeId,
	DataDimensions dimensions,
	out bool created
)

Parameters

attrDb
Type: Demo3D.PLC.Comms.AttrDbIAttributeDatabase
The attribute database.
attributeId
Type: SystemUInt32
The attribute id to find.
dimensions
Type: Demo3D.PLC.Comms.AttrDbDataDimensions
The data dimension selection from the request that's accessing the attribute value.
created
Type: SystemBoolean
True if the value was created.

Return Value

Type: AttributeValue
The new/existing attribute value.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IAttributeDatabase. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also