The SimConnect_RequestFacilityData_EX1 function is used to request data according to a predefined object, an ICAO and a region. This function is practically identical in functionality to the SimConnect_RequestFacilityData function, only it has an additional return value used to identify waypoints when there is an ICAO/Region overlap with VOR or NDB.


HRESULT SimConnect_RequestFacilityData(
    HANDLE hSimConnect,
    const char * ICAO,
    const char * Region = "",
    char Type = 0


Parameter Description Type
hSimConnect Handle to a SimConnect object. Integer
DefineID Specifies the ID of the client defined data definition Integer
RequestID The client defined request ID Integer
ICAO Used to identify an airport, a VOR, an NDB or a waypoint. Char

Additional identifier for an airport, a VOR, an NDB or a waypoint. For airports, this can be omitted without issue, however for VOR / NDB / Waypoints this should be supplied if possible, although there are workarounds provided if it's not (see remarks, below).


Additional identifier for when requesting data to differentciate between waypoint/VOR/NDB when there are overlapping ICAO/Region identifiers. Should be one of the following ASCii values:

  1. 86 ('V') - VOR
  2. 78 ('N') - NDB
  3. 87 ('W') - Waypoint


Return Values

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

Return value Description
S_OK The function succeeded.
E_FAIL The function failed.
SIMCONNECT_EXCEPTION_UNRECOGNIZED_ID The function has an invalid DefineId.
SIMCONNECT_EXCEPTION_ERROR The function was supplied an invalid ICAO and/or Region parameter.



If the Request works, the client will receive as many messages (SIMCONNECT_RECV_FACILITY_DATA) as necessary to match the defined architecture. At the end, the server will send a SIMCONNECT_RECV_FACILITY_DATA_END message to let the client know that everything is finished. For an example of use and more information, please see SimConnect_AddToFacilityDefinition.


Note that it is possible to request a Waypoint/NDB/VOR using only the ICAO and no region. When doing so, if there is no duplicated ICAO, then the appropriate data will be returned. However, if there is a conflict between multiple ICAO's, the function will return only those that correspond to the given "Type".


See Also