Junch / dllhelper

How to GetProcAddress() like a boss 😎

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to GetProcAddress like a boss 😎

Demonstrates how to leverage modern C++ features to simplify manual DLL linking.

class ShellApi {
  DllHelper _dll{"Shell32.dll"};

public:
  decltype(ShellAboutA) *shellAbout = _dll["ShellAboutA"];
};

int main() {
  ShellApi shellApi;
  shellApi.shellAbout(NULL, "hello", "world", NULL);
}

See blog post

About

How to GetProcAddress() like a boss 😎

License:MIT License


Languages

Language:C++ 64.7%Language:C 23.5%Language:CMake 11.8%