标签:adl type lib test null apt code def hwnd
#include <windows.h>
typedef int(__stdcall *pMessageBoxA)(HWND hWnd, LPCSTR lpText, LPCSTR lpCaption, UINT uType);
using pFnMessageBoxA = int(__stdcall *)(HWND hWnd, LPCSTR lpText, LPCSTR lpCaption, UINT uType);
int main()
{
pMessageBoxA MessageBoxA1 = (pMessageBoxA)GetProcAddress(LoadLibraryA("User32.dll"), "MessageBoxA");
pFnMessageBoxA MessageBoxA2 = (pFnMessageBoxA)GetProcAddress(LoadLibraryA("User32.dll"), "MessageBoxA");
MessageBoxA1(NULL, "test1", "test", 0);
MessageBoxA2(NULL, "test2", "test", 0);
return 0;
}
标签:adl type lib test null apt code def hwnd
原文地址:https://www.cnblogs.com/Lnju/p/10666794.html