Method MatrixSetLabel
- Namespace
- Skyline.DataMiner.Automation
- Assembly
- SLManagedAutomation.dll
MatrixSetLabel(int, bool, int, string)
Sets the label of the specified matrix input or output.
public virtual void MatrixSetLabel(int pid, bool input, int index, string newName)
Parameters
pidintThe ID of the matrix parameter.
inputbooltrueif the specified index is an input; otherwise,false.indexintThe index of the input or output.
newNamestringThe new label.
Examples
var dummy = engine.GetDummy("dummy1");
dummy.MatrixSetLabel(1000, true, 4, "Main");
Remarks
index must be in the range 1..nrOfInputs if input is true.
index must be in the range 1..nrOfOutputs if input is false.
Exceptions
- DataMinerException
The matrix parameter was not found.
-or-
indexis not in the range 1..nrOfInputs andinputistrue.
-or-
indexis not in the range 1..nrOfOutputs andinputisfalse.
MatrixSetLabel(int, bool, string, string)
Sets the label of the specified matrix input or output.
public virtual void MatrixSetLabel(int pid, bool input, string oldName, string newName)
Parameters
pidintThe ID of the matrix parameter.
inputbooltrueif the specified index is an input; otherwise,false.oldNamestringThe label of the input or output.
newNamestringThe new label.
Examples
var dummy = engine.GetDummy("dummy1");
dummy.MatrixSetLabel(1000, true, "Input 1", "Main");
Exceptions
- DataMinerException
The matrix parameter was not found.
-or-
inputistrueand there is no input with the specified label.
-or-
inputisfalseand there is no output with the specified label.
MatrixSetLabel(string, bool, int, string)
Sets the label of the specified matrix input or output.
note
Please use an overload that takes the parameter ID instead to prevent issues in case the parameter Description changes.
[Obsolete("Use overloads with parameter ID instead of name.")]
public virtual void MatrixSetLabel(string parameterName, bool input, int index, string newName)
Parameters
parameterNamestringThe name of the matrix parameter.
inputbooltrueif the specified index is an input; otherwise,false.indexintThe index of the input or output.
newNamestringThe new label.
Examples
var dummy = engine.GetDummy("dummy1");
dummy.MatrixSetLabel("Example Matrix", true, 4, "Main");
Remarks
The specified value for the parameterName argument should be the value of the Description tag of the parameter and not the value of the Name tag.
index must be in the range 1..nrOfInputs if input is true.
index must be in the range 1..nrOfOutputs if input is false.
Exceptions
- DataMinerException
The matrix parameter was not found.
-or-
indexis not in the range 1..nrOfInputs andinputistrue.
-or-
indexis not in the range 1..nrOfOutputs andinputisfalse.
MatrixSetLabel(string, bool, string, string)
Sets the label of the specified matrix input or output.
note
Please use an overload that takes the parameter ID instead to prevent issues in case the parameter Description changes.
[Obsolete("Use overloads with parameter ID instead of name.")]
public virtual void MatrixSetLabel(string parameterName, bool input, string oldName, string newName)
Parameters
parameterNamestringThe name of the matrix parameter.
inputbooltrueif the specified index is an input; otherwise,false.oldNamestringThe label of the input or output.
newNamestringThe new label.
Examples
var dummy = engine.GetDummy("dummy1");
dummy.MatrixSetLabel("Example Matrix", true, "Input 1", "Main");
Remarks
The specified value for the parameterName argument should be the value of the Description tag of the parameter and not the value of the Name tag.
Exceptions
- DataMinerException
The matrix parameter was not found.
-or-
inputistrueand there is no input with the specified label.
-or-
inputisfalseand there is no output with the specified label.