DANSrvAE Reference
SetItemValue Method
See Also  Send comments on this topic.
NSPlugin Assembly > NSPlugin Namespace > GenericServer Class : SetItemValue Method

AppItemHandle
Item handle as defined in the AddItem method call.
newValue
Object with new item value. The value must match the canonical data type of this item. The canonical date type is the type of the value in the cache and is defined in the AddItem method call.
null can be passed to change only the quality and timestamp.
quality
New quality of the item value. This is a short value ( Int16) with a value of the OPCQuality enumerator.
timestamp
Timestamp of the new item value.

Glossary Item Box

Generic server callback method.

Write an item value into the cache.

Syntax

Visual Basic (Declaration) 
Public Shared Function SetItemValue( _
   ByVal AppItemHandle As Integer, _
   ByVal newValue As Object, _
   ByVal quality As Short, _
   ByVal timestamp As Date _
) As Integer
C# 
public static int SetItemValue( 
   int AppItemHandle,
   object newValue,
   short quality,
   DateTime timestamp
)

Parameters

AppItemHandle
Item handle as defined in the AddItem method call.
newValue
Object with new item value. The value must match the canonical data type of this item. The canonical date type is the type of the value in the cache and is defined in the AddItem method call.
null can be passed to change only the quality and timestamp.
quality
New quality of the item value. This is a short value ( Int16) with a value of the OPCQuality enumerator.
timestamp
Timestamp of the new item value.

Return Value

Returns S_OK if the value was successfully written into the cache.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

© 2004-2017 Advosol Inc. All Rights Reserved.