C_AttachToThread

Call C_AttachToThread to assign thread affinity for a model to the calling thread. This function can only be called after first calling C_DetachFromThread.

void C_AttachToThread(

TOrcFxAPIHandle ModelHandle,

int *lpStatus

);

Parameters

ModelHandle (IN)

The handle of the model.

lpStatus (OUT)

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

Remarks

A model can be assigned affinity to a different thread by taking the following steps:

  1. Call C_DetachFromThread from the thread to which the model currently has affinity.
  2. Call C_AttachToThread from a different thread, after which the model will have affinity to this thread.

See also

C_DetachFromThread.