Table of Contents

Method AddRow

Namespace
Skyline.DataMiner.Scripting
Assembly
SLManagedScripting.dll

AddRow(int, object[])

Adds a row to the table.

int AddRow(int tableId, object[] row)

Parameters

tableId int

The ID of the table parameter.

row object[]

The row data.

Returns

int

The 1-based internal position of the row in the table.

Remarks

  • This method acts as a wrapper for a NotifyProtocol type 149 call NT_ADD_ROW.
  • Available from DataMiner 10.1.1 (RN 27995) onwards. Prior to DataMiner 10.1.1 (RN 27995), this method was defined as an SLProtocol extension method in the NotifyProtocol class.
  • To add a row with a specific timestamp:

    row (object[]):

    • row[0] (object[]): the row data
    • row[1] (DateTime): the timestamp
    int tableID = 1000;
          object rowData = new object[] { "Key 200", "S", "20.20" };
          DateTime timeStamp = DateTime.Now - TimeSpan.FromDays(2);
    
      protocol.AddRow(tableId, new object[] { rowData, timeStamp});</code></pre>
    </li></ul>
    

AddRow(int, string)

Adds a row to the specified table with the specified primary key.

int AddRow(int tableId, string row)

Parameters

tableId int

The ID of the table parameter.

row string

The primary key of the row.

Returns

int

The 1-based internal position of the row in the table.

Remarks

  • This method acts as a wrapper for a NotifyProtocol type 149 call NT_ADD_ROW.
  • Prior to DataMiner 10.1.1 (RN 27995), this method was defined as an SLProtocol extension method in the NotifyProtocol class.

AddRow(int, object[], bool[])

Adds the specified row to the specified table.

void AddRow(int tableId, object[] row, bool[] keyMask)

Parameters

tableId int

The ID of the table parameter.

row object[]

The row data.

keyMask bool[]

Sets are done in two calls. The first call only sets the columns where the corresponding mask position is set to true, the second call then sets the other columns.

Remarks

  • This method acts as a wrapper for a NotifyProtocol type 149 call NT_ADD_ROW.
  • Available from DataMiner 10.1.1 (RN 27995) onwards. Prior to DataMiner 10.1.1 (RN 27995), this method was defined as an SLProtocol extension method in the NotifyProtocol class.

Exceptions

ArgumentException

The row and key mask arrays have a different length.