home *** CD-ROM | disk | FTP | other *** search
/ Prima Shareware 3 / DuCom_Prima-Shareware-3_cd1.bin / PROGRAMO / C / MRCE / SOURCE.ZIP / MRCEXT.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1995-09-11  |  1.9 KB  |  56 lines

  1. // MRCEXT: Micro Focus Extension DLL for MFC 2.1+
  2. // Copyright (C)1994-5    Micro Focus Inc, 2465 East Bayshore Rd, Palo Alto, CA 94303.
  3. // 
  4. //  This program is free software; you can redistribute it and/or modify
  5. //  it under the terms of the GNU General Public License as published by
  6. //  the Free Software Foundation. In addition, you may also charge for any
  7. //  application    using MRCEXT, and are under no obligation to supply source
  8. //  code. You must accredit Micro Focus Inc in the "About Box", or banner
  9. //  of your application. 
  10. //
  11. //  This program is distributed in the hope that it will be useful,
  12. //  but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14. //  GNU General Public License for more details.
  15. //
  16. //  You should also have received a copy of the GNU General Public License with this
  17. //  software, also indicating additional rights you have when using MRCEXT.  
  18. //
  19. //
  20. // MRCEXT.CPP
  21. // $Date:   11 Sep 1995 09:46:32  $
  22. // $Revision:   1.2  $
  23. // $Author:   MRC  $
  24. // mrcext.cpp : Defines the initialization routines for the DLL.
  25. //
  26.  
  27. #include "mrcstafx.h"
  28. #include <afxdllx.h>
  29.  
  30. #ifdef _DEBUG
  31. #undef THIS_FILE
  32. static char BASED_CODE THIS_FILE[] = __FILE__;
  33. #endif
  34.  
  35. static AFX_EXTENSION_MODULE mrcextDLL = { NULL, NULL };
  36.  
  37. extern "C" int APIENTRY
  38. DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
  39. {
  40.         if (dwReason == DLL_PROCESS_ATTACH)
  41.         {
  42.                 TRACE0("MRCEXT.DLL Initializing! - (C)1995 Micro Focus Ltd\n");
  43.  
  44.                 // Extension DLL one-time initialization
  45.                 AfxInitExtensionModule(mrcextDLL, hInstance);
  46.  
  47.                 // Insert this DLL into the resource chain
  48.                 new CDynLinkLibrary(mrcextDLL);
  49.         }
  50.         else if (dwReason == DLL_PROCESS_DETACH)
  51.         {
  52.                 TRACE0("MRCEXT.DLL Terminating!\n");
  53.         }
  54.         return 1;   // ok
  55. }
  56.