Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <windows.h>
- #include <stdio.h>
- typedef void (WINAPI *PRUNDLL)(HWND hWnd, HINSTANCE hInst, LPCWSTR cmd, DWORD nCmdShow);
- int main()
- {
- HINSTANCE hinstLib;
- PRUNDLL pRunDll;
- hinstLib = LoadLibrary(TEXT("shell32.dll"));
- if (NULL != hinstLib)
- {
- pRunDll = (PRUNDLL)GetProcAddress(hinstLib, "Control_RunDLLW");
- if (NULL != pRunDll)
- {
- pRunDll(0, 0, L"Testing 1 2 3", SW_SHOW);
- }
- else
- {
- printf("ERROR: couldn't find function\n");
- }
- }
- else
- {
- printf("ERROR: couldn't load shell32.dll\n");
- }
- return 0;
- }
Add Comment
Please, Sign In to add comment