Table of Contents

Method SetValue

Namespace
Skyline.DataMiner.Core.DataMinerSystem.Common
Assembly
Skyline.DataMiner.Core.DataMinerSystem.Common.dll

SetValue(string, T)

Sets the value of a cell in a table.

void SetValue(string primaryKey, T value)

Parameters

primaryKey string

The primary key of the row.

value T

The value to set.

Examples

IDms myDms = protocol.GetDms();
IDmsElement element = myDms.GetElement(new DmsElementId(346, 100));
var table = element.GetTable(1000);
var column = table.GetColumn<double?>(1004);

column.SetValue("PK 1", 10.0);

Exceptions

ArgumentNullException

primaryKey is null.

ElementNotFoundException

The element was not found in the DataMiner System.

ElementStoppedException

The element is stopped.

SetValue(string, KeyType, T)

Sets the value of a cell in a table.

void SetValue(string key, KeyType keyType, T value)

Parameters

key string

The key of the row.

keyType KeyType

The key type.

value T

The value to set.

Examples

IDms myDms = protocol.GetDms();
IDmsElement element = myDms.GetElement(new DmsElementId(346, 100));
var table = element.GetTable(1000);
var column = table.GetColumn<double?>(1004);

column.SetValue("PK 1", KeyType.PrimaryKey, 10.0);

Exceptions

ElementNotFoundException

The element was not found in the DataMiner System.

ElementStoppedException

The element is stopped.

SetValue(string, KeyType, T, TimeSpan, ExpectedChanges)

Sets the value of a cell in a table and waits on specified expected changes.

void SetValue(string key, KeyType keyType, T value, TimeSpan timeout, ExpectedChanges expectedChanges)

Parameters

key string

The key of the row.

keyType KeyType

The key type.

value T

The value to set.

timeout TimeSpan

The maximum time to wait on the expected change.

expectedChanges ExpectedChanges

One or more expected changes. Can be CellValue or ParamValue

Exceptions

ArgumentNullException

key, expectedChanges is null.

ElementNotFoundException

The element was not found in the DataMiner System.

ElementStoppedException

The element is stopped.

TimeoutException

Expected change took too long.

FormatException

One of the provided parameters is missing data.