The
netapi32.dll is part of Windows and is located in the Windows system directory like all other system DLLs.
To use functions from this DLL, you must link your application against the
netapi32.lib library file. This library is provided by the Windows SDK which should be already installed on your system when using Visual Studio.
How to add the library to your project depends on the used development environment. At first you should ensure that the path to the Lib folder of your SDK installation is part of the library search pathes of your linker project settings. Then just add the library name to your project settings.
When using Visual studio, you may specify the library name also in the source file:
#pragma comment(lib, "netapi32.lib")