1. #include <windows.h>
  2.  
  3. typedef struct {
  4.   long a;
  5.   long b;
  6.   long c;
  7.   long d;
  8.   long e;
  9.   long f;
  10. } Data;
  11.  
  12. typedef int (WINAPIV* LPFN_PROJECTORMAIN) (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow, Data *data);
  13.  
  14. int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow){
  15.   HINSTANCE hLib = LoadLibraryA("proj.dll");
  16.   if (hLib){
  17.     LPFN_PROJECTORMAIN fnMain = (LPFN_PROJECTORMAIN)GetProcAddress(hLib, "ProjectorMain");
  18.     if (fnMain){
  19.       Data data = {0};
  20.       fnMain(hInstance, hPrevInstance, lpCmdLine, nCmdShow, &data);
  21.     }
  22.     FreeLibrary(hLib);
  23.   }
  24.   return 0;
  25. }
  26.  
[raw code]