C_EnumerateVars2

C_EnumerateVars2 is called to obtain a list of all available results variables.

You specify the object and the type of result (time history, range graph or linked statistics). Then the callback function EnumerateVarsProc is called once for each available results variable and passed details of that results variable. If you just wish to find out how many available results variables there are then pass NULL for the EnumerateVarsProc parameter.

void C_EnumerateVars2(

TOrcFxAPIHandle ObjectHandle,

const TObjectExtra2 *lpObjectExtra,

int ResultType,

TEnumerateVarsProc EnumerateVarsProc,

int *lpNumberOfVars,

int *lpStatus

);

Parameters

ObjectHandle (IN)

The handle of the object for which you want available results variable information.

lpObjectExtra (IN)

Points to a TObjectExtra2 variable which specifies where on the object results are required.

Only needed if both the following conditions hold:

  1. The object is the environment or a line, or if you want results for a wing attached to a 6D buoy, or if you want position results for a winch.
  2. ResultType is rtTimeHistory, rtLinkedStatistics or rtFrequencyDomain.

Otherwise pass NULL.

ResultType (IN)

One of rtTimeHistory, rtRangeGraph, rtLinkedStatistics or rtFrequencyDomain. These constants are defined in the C++ header file OrcFxAPI.h.

EnumerateVarsProc (IN)

A callback function to handle enumeration of the results variables. This callback function is called once for each available results variable. You can pass NULL for this parameter if you only want to find out how many available results variables there are.

lpNumberOfVars (OUT)

Points to a variable in which the number of available results variables is returned. The callback function EnumerateVarsProc will be called this many times – once for each available results variable.

lpStatus (OUT)

Points to a variable in which the status result for the function call will be returned.

Unicode and ANSI

The Unicode function name is C_EnumerateVars2W and the ANSI function name is C_EnumerateVars2A.

See also

TObjectExtra2, TVarInfo, EnumerateVarsProc.