The SimConnect_SubscribeToFlowEvent function is used to receive a SIMCONNECT_RECV_FLOW_EVENT message when the simulation triggers some flow events, for example during a Back On Track event.

 

You can find a sample project to use as a reference when using the Flow API here:

 

Syntax
HRESULT SimConnect_SubscribeToFlowEvent(
    HANDLE  hSimConnect
    );

 

Parameters
ParameterDescriptionType
hSimConnectHandle to a SimConnect object.Integer

  

Return Values

The function returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return valueDescription
S_OKThe function succeeded.
E_FAILThe function failed.