DOCUMENTATION NTi

RetrieveSystemValues() method

Description

The RetrieveSystemValues method queries the QWCRSVAL API for a set of specified system values.
It returns a list of objects of type SystemValueInformation containing details of each system value retrieved.
This method can process a maximum of 158 system values in a single call.

Syntax

RetrieveSystemValues(string[] validSystemValues)

Parameters

Name Type Description
validSystemValues string[] An array containing the names of the system values to be retrieved. Each name must not exceed 10 characters and the array can contain up to 158 system values.

Return

Returns a list of objects of type SystemValueInformation which contains details of each system value retrieved.

SystemValueInformation Class

Property Type Description
SystemValue string The name of the system value.
DataType string The data type of the system value, represented as a string.
InformationStatus string Status of system value information.
LengthOfData int Length of the system value data, in number of bytes.
Data object The actual value of the system value in the form of a generic object.

Exceptions

  • ArgumentOutOfRangeException : Thrown if the array contains more than 158 system value names.
  • InvalidOperationException : Thrown if the size of the returned data is insufficient to process the request, or if an error occurs during execution.

Examples of use

var systemValues = conn.RetrieveSystemValues(new string[] { ‘QTIME’, ‘QDATE’ }); 
foreach (var systemValue in systemValues) 
{
    Console.WriteLine($‘System Value: {systemValue.SystemValue}, Data: {systemValue.Data}’);
}

References

For more information on the QWCRSVAL API, see the official IBM documentation.