Tags

Please note that the most efficient way to add tags and set their properties programmatically is using the TagCSVImport method.

GetTagValuesByGroup

The GetTagValuesByGroup Function returns an array of Tag Names and Values for all of the Tags in the specified group. Tag Names and Values are alternating with the the array of tags.

Returns Empty Array if service is not reachable.

The returned array of objects will contain first the tag name followed by the value.

Example is element 0 contains Tag01, element 1 contains the value of Tag01 element 2 contains Tag02, element 3 contains the value of Tag02.

If the data quality of the Tag value is bad the individual returned value will be null.

The GroupName is the reference path of the group to get the values from.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

The GetTagNames Function returns a list of Tags in the specified ReferenceGroup path.

Returns Empty String if service is not reachable.

Returns a String Array of Tags in the ReferenceGroup.

ReferenceGroup is a string of the Group path to retrieve the Tags from.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

GetAllTagNames

The GetAllTagNames Function returns a list of all of the Tags from the specified ReferenceGroup path and all tags in all sub groups within the Reference Group.

Returns Empty String Array if service is not reachable.

Returns a String Array of Tags in the ReferenceGroup and all tags within the sub groups of the Reference Group.

ReferenceGroup is a string of the Group path to retrieve the Tags from.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

ErrorString will be set to Success when function is successful and an error message when in error.

RemoteSCADAHostingName is the name of the Live Data Cloud OAS Service to connect to.”

VB

AddTag

The AddTag Function adds a Tag to the existing Tag configuration.

*** Note to add multiple Tags with mutliple parameters use the TagCSVImport method as demonstrated under Configure-Tags

Returns -1 if service is not reachable.

Returns 1 if successful.

Returns 0 if the Tag already exists or adding the Tag failed.

Tag is the name of the Tag to add.

ReferenceGroup is a string of the Group path to add the Tag to.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message is in error.

VB

RemoveTag

The RemoveTag Function removes a Tag to the existing Tag configuration.

Returns -1 if service is not reachable.

Returns 1 if successful.

Returns 0 if the Tag does not exist..

Tag is the name of the Tag to remove.

ReferenceGroup is a string of the Group path to remove the Tag from.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message is in error.

VB

DeleteAllTags

The DeleteAllTags Function removes all Tags from the existing Tag configuration.

Returns -1 if service is not reachable.

Returns 0 if error occurs.

Returns 1 if successful.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

GetTag_Parameter_Strings

The GetTag_Parameter_Strings Function returns an array of Strings containing all Parameter Types available for each Tag.

Returns Empty String Array if service is not reachable.

Returns a String Array of Parameter Types for all Tags.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

VB

Private Sub ComboBoxGetTag_Parameter_Strings_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBoxGetTag_Parameter_Strings.SelectedIndexChanged
TextBoxParameter.Text = ComboBoxGetTag_Parameter_Strings.SelectedItem

C#

GetParameter_Property_Strings

The GetParameter_Property_Strings Function returns an array of Strings containing all property types available for each Parameter.

Returns Empty String Array if service is not reachable.

Returns a String Array of property types for all Parameters.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

VB

GetTag_Parameter_Value

The GetTag_Parameter_Value Function returns an object value for the Tag.Parameter.Property specified.

Returns nothing if service is not reachable.

Parameter is a String of the Parameter Type desired of the Tag.

PropertyType is a String of the Property Type desired of the Parameter.

TagName is a String of the Tag desired.

ReferenceGroup is a String of the Group(s) where the Tag is to be contained.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

GetTag_Parameter_Values

The GetTag_Parameter_Values Function returns an array of object values for the Tag.Parameter specified.

The order of the array corresponds with the GetParameter_Property_Strings Function order.

Returns empty array if service is not reachable.

Parameter is a String of the Parameter Type desired of the Tag.

TagName is a String of the Tag desired.

ReferenceGroup is a String of the Group(s) where the Tag is to be contained.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

VB

SetTag_Parameter_Value

The SetTag_Parameter_Value Function sets an object value for the Tag.Parameter.Property specified.

Returns -1 if service is not reachable.

Returns 1 if the function was successful.

Parameter is a String of the Parameter Type desired of the Tag.

PropertyType is a String of the Property Type desired of the Parameter.

Value is the desired value to set.

TagName is a String of the Tag desired.

ReferenceGroup is a String of the Group(s) where the Tag is to be contained.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

SaveTagConfiguration

The SaveTagConfiguration Subroutine saves the current Tag configuration to the specified file path.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

LoadTagConfiguration

The LoadTagConfiguration Subroutine saves the current Tag configuration to the specified file path.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

CheckTagAccessRead

The CheckTagAccessRead Function returns a list of Tags that have read access from the UserName and Password specified.

This method requires Security access for Get Secuirty Parameters from the user and password specified in the LogIn method of the component.

Returns Empty String Array if service is not reachable.

Returns a String Array of Tags that are allowed for Read Access.

UserName is the user to verify with the Tags.

Password is the password of the user to verify with the Tags.

Tags is a list of tags to check in the service, do not include the remote network path in the tag names.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB

CheckTagAccessWrite

The CheckTagAccessWrite Function returns a list of Tags that have write access from the UserName and Password specified.

This method requires Security access for Get Secuirty Parameters from the user and password specified in the LogIn method of the component.

Returns Empty String Array if service is not reachable.

Returns a String Array of Tags that are allowed for Write Access.

UserName is the user to verify with the Tags.

Password is the password of the user to verify with the Tags.

Tags is a list of tags to check in the service, do not include the remote network path in the tag names.

NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.

Optional ErrorString will be set to Success when function is successful and an error message when in error.

VB