ChangeTagPropertyUserFunction

Parent Previous Next

ChangeTagPropertyUserFunction

Function that changes the property using a function.


Syntax:

Void ChangeTagPropertyUserFunction(Dictionary<string, object> properties);


Void ChangeTagPropertyUserFunction(string propertyName, object value);


Params:

Dictionary properties: A dictionary parameter that contains the properties of the tag.

String propertyName: The name of the property to set value.

Object value: The value to set to the property.


Example: Dictionary

Setting the MinRaw and the MaxRaw of tags NewTag1 and NewTag2:



Dictionary<string,object> propsToChange = new Dictionary<string,object>();


propsToChange.Add("NewTag1.MaxRaw", 5000);

propsToChange.Add("NewTag1.MinRaw", -5000);

propsToChange.Add("NewTag2.MaxRaw", 5000);

propsToChange.Add("NewTag2.MinRaw", -5000);


SVTags.ChangeTagPropertyUserFunction(propsToChange);

 



Example: String, Object

            Setting the MinRaw and the MaxRaw of tags NewTag1 and NewTag2:

  


SVTags.ChangeTagPropertyUserFunction("NewTag1.MaxRaw", 5000);

SVTags.ChangeTagPropertyUserFunction("NewTag1.MinRaw", -5000);

SVTags.ChangeTagPropertyUserFunction("NewTag2.MaxRaw", 5000);

SVTags.ChangeTagPropertyUserFunction("NewTag2.MinRaw", -5000);