DyLibLoad
Loads to a Dynamic Link Library (DLL) into memory at runtime
Syntax
`
Declare Function DyLibLoad ( ByRef filename As String ) As Any Pointer
`
Usage
`
result = DyLibLoad ( filename )
`
Parameters
`filename`
A `String` containing the filename of the library to load.
Return Value
The `Pointer` handle of the library loaded. Zero on error
Description
`DyLibLoad` is used to link at runtime libraries to your program. This function does the link and returns a handle that must be used with `DyLibSymbol` when calling a function in the library and with `DyLibFree` when releasing the library.
Note: If the `filename` string (without extension) already includes a character dot (`.`), it may be mandatory to explicitly specify the filename extension to avoid any parser ambiguity.
Example
See the dynamic loading example on the Shared Libraries page.
Platform Differences

- Dynamic link libraries are not available in DOS, as the OS doesn't support them.

Dialect Differences

- Not available in the -lang qb dialect unless referenced with the alias `__Dylibload`.

Differences from QB

- New to FreeBASIC

See also

- `DyLibSymbol`
- `DyLibFree`
- `Export`