
'Declaration
<CLSCompliantAttribute(True)> <ComDefaultInterfaceAttribute(OpcLabs.EasyOpc.DataAccess.OperationModel.ComTypes._DAPropertyArguments)> <ComVisibleAttribute(True)> <GuidAttribute("D310A9B5-12AB-4B1C-9D65-801E1336EB8F")> <TypeConverterAttribute(System.ComponentModel.ExpandableObjectConverter)> <ValueControlAttribute("OpcLabs.BaseLib.Forms.Common.ObjectSerializationControl, OpcLabs.BaseLibForms, Version=5.63.115.1, Culture=neutral, PublicKeyToken=6faddca41dacb409", DefaultReadWrite=False, Export=True, PageId=10001)> <SerializableAttribute()> Public NotInheritable Class DAPropertyArguments Inherits OpcLabs.BaseLib.OperationModel.OperationArguments Implements LINQPad.ICustomMemberProvider, OpcLabs.BaseLib.ComTypes._Info, OpcLabs.BaseLib.ComTypes._Object2, OpcLabs.BaseLib.OperationModel.ComTypes._OperationArguments, OpcLabs.EasyOpc.DataAccess.OperationModel.ComTypes._DAPropertyArguments, System.ICloneable, System.Runtime.Serialization.ISerializable, System.Xml.Serialization.IXmlSerializable
'Usage
Dim instance As DAPropertyArguments
[CLSCompliant(true)] [ComDefaultInterface(OpcLabs.EasyOpc.DataAccess.OperationModel.ComTypes._DAPropertyArguments)] [ComVisible(true)] [Guid("D310A9B5-12AB-4B1C-9D65-801E1336EB8F")] [TypeConverter(System.ComponentModel.ExpandableObjectConverter)] [ValueControl("OpcLabs.BaseLib.Forms.Common.ObjectSerializationControl, OpcLabs.BaseLibForms, Version=5.63.115.1, Culture=neutral, PublicKeyToken=6faddca41dacb409", DefaultReadWrite=false, Export=true, PageId=10001)] [Serializable()] public sealed class DAPropertyArguments : OpcLabs.BaseLib.OperationModel.OperationArguments, LINQPad.ICustomMemberProvider, OpcLabs.BaseLib.ComTypes._Info, OpcLabs.BaseLib.ComTypes._Object2, OpcLabs.BaseLib.OperationModel.ComTypes._OperationArguments, OpcLabs.EasyOpc.DataAccess.OperationModel.ComTypes._DAPropertyArguments, System.ICloneable, System.Runtime.Serialization.ISerializable, System.Xml.Serialization.IXmlSerializable
[CLSCompliant(true)] [ComDefaultInterface(OpcLabs.EasyOpc.DataAccess.OperationModel.ComTypes._DAPropertyArguments)] [ComVisible(true)] [Guid("D310A9B5-12AB-4B1C-9D65-801E1336EB8F")] [TypeConverter(System.ComponentModel.ExpandableObjectConverter)] [ValueControl("OpcLabs.BaseLib.Forms.Common.ObjectSerializationControl, OpcLabs.BaseLibForms, Version=5.63.115.1, Culture=neutral, PublicKeyToken=6faddca41dacb409", DefaultReadWrite=false, Export=true, PageId=10001)] [Serializable()] public ref class DAPropertyArguments sealed : public OpcLabs.BaseLib.OperationModel.OperationArguments, LINQPad.ICustomMemberProvider, OpcLabs.BaseLib.ComTypes._Info, OpcLabs.BaseLib.ComTypes._Object2, OpcLabs.BaseLib.OperationModel.ComTypes._OperationArguments, OpcLabs.EasyOpc.DataAccess.OperationModel.ComTypes._DAPropertyArguments, System.ICloneable, System.Runtime.Serialization.ISerializable, System.Xml.Serialization.IXmlSerializable
Each OPC item has typically associated a set of OPC properties with it. OPC properties contain additional information related to the item.
If you want to obtain the value of specific OPC property, call the GetPropertyValue method, passing it the machine name, server class, the ItemId, and a PropertyId. You will receive back an Object (a VARIANT in QuickOPC-COM) containing the value of the requested property.
The GetPropertyValue Method returns a generic object, regardless of the property involved. You may therefore need to cast the returned value to the expected type, and possibly do further processing on the value, as in the the example below.
In QuickOPC.NET, you can also pass in the ServerDescriptor inplace of the machine name and server class strings.
In addition to basic methods, there are also many property-related methods. Please refer to a chapter in this document that describes EasyOPC.NET Extensions.
For obtaining multiple properties simultaneously in an efficient manner, call the GetMultiplePropertyValues method (instead of multiple GetPropertyValue calls in a loop). The arguments are similar, except that in place of a single PropertyId you pass in an array of them. You will receive back an array of Object values (a SAFEARRAY of VARIANT values in QuickOPC-COM).
The example below is a bit more complex, and combines the ability to browse for items with getting the data type property for each of the items obtained.
The example below combines the ability to browse for items with getting the data type property for each of the items obtained, for OPC XML-DA Servers.
System.Object
OpcLabs.BaseLib.Object2
OpcLabs.BaseLib.Info
OpcLabs.BaseLib.OperationModel.OperationArguments
OpcLabs.EasyOpc.DataAccess.OperationModel.DAPropertyArguments
Target Platforms: .NET Framework: Windows 10 (selected versions), Windows 11 (selected versions), Windows Server 2012, Windows Server 2016; .NET Core, .NET 5, .NET 6: Linux, macOS, Microsoft Windows