Accessing Functions in DLLs
- Last UpdatedJul 18, 2023
- 1 minute read
To be able to call and use an external DLL function using VBA, you must have previously provided VBA with details about the function being called. VBA requires information like the name of the function, where that function is located, what arguments it expects, and what type of data it returns. VBA uses the Declare statement to detail that information.
The Declare statement must be positioned in the VBA file in your project above and before any code that calls that declared function of the DLL.