AnalysisSetResultValue

You can use the AnalysisSetResultValue to update the result of a specified parameter in the Analysis form for a given row tag.

Note: This function enables programmatic modification of analysis test results within Optiva.

When to use

You can use this function when updating the specific parameter value in the analysis result grid programmatically.

When not to use

You cannot use this function when:

  • Updating analysis header information instead of result grid data.
  • The parameter or row tag is not in the Analysis form structure.
  • The analysis record which cannot be modified or locked.

Syntax

long AnalysisSetResultValue(string RowTag, string ParamCode, object NewValue)

Parameters

Parameter Type Required Description
RowTag string Yes The analysis row tag name in the result data grid. The parameters identifies the specific row in the analysis results where the parameter value will be updated.
ParamCode string Yes The parameter code identifying the specific parameter value to be update.
Note: The code must correspond to an existing parameter in the Analysis form.
NewValue object Yes The new value to be assigned to the parameter in the analysis result grid.
Note: The value type must match the parameters data type (numeric, string, date, etc.).

Return Value

The application returns a value greater than zero (0) if the operation is successful.

Prerequisites

  • The user must have permission to modify the analysis object.
  • The analysis record must be modifiable.
  • The parameter must exist and be configured for the specific analysis type.
  • The Row tag must exist in the analysis result grid.

Examples

AnalysisSetResultValue("PROPOSED", _ANALYSISPARAM, 100);
Description
This example sets the current parameter to 100 for the PROPOSED result row tag.