Dynamic Loading

Get Function Table

lgo_GetFunctionTable()

Retrieve a pointer to the LayGO API function table from the last loaded DLL.

Syntax
#include "laygodll.h"

LaygoFunctionTable  lgo_GetFunctionTable
    (
        void
    );
Description

lgo_GetFunctionTable() retrieves a pointer to the LayGO function table contained in the last DLL loaded by lgo_LoadLaygoDll(). If no DLL has been loaded, it returns NULL. The return value of this function is the same as the value of the global variable lgo_Fn.

Return Values

If successful, lgo_GetFunctionTable() returns a non-NULL pointer to the function table. Otherwise, it returns NULL.

See Also

lgo_LoadLaygoDll()

Example
LaygoFunctionTable table = NULL;

if (lgo_LoadLaygoDll(lgo_DLL_RPC) < 0)
{
    printf("Error: failure loading LayGO DLL.\n");
}
else
{
    table = lgo_GetFunctionTable();
}