home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / sdk / com / inole2 / chap06 / ianimal / libmain.cpp < prev    next >
C/C++ Source or Header  |  1995-05-03  |  693b  |  40 lines

  1. /*
  2.  * LIBMAIN.CPP
  3.  * IAnimal Interface DLL Chapter 6
  4.  *
  5.  * Entry point code
  6.  *
  7.  * Copyright (c)1993-1995 Microsoft Corporation, All Rights Reserved
  8.  *
  9.  * Kraig Brockschmidt, Microsoft
  10.  * Internet  :  kraigb@microsoft.com
  11.  * Compuserve:  >INTERNET:kraigb@microsoft.com
  12.  */
  13.  
  14.  
  15. #include <windows.h>
  16.  
  17.  
  18. /*
  19.  * LibMain(32)
  20.  *
  21.  * Purpose:
  22.  *  Entry point for Win32 DLLs
  23.  */
  24.  
  25. BOOL WINAPI LibMain32(HINSTANCE hInstance, ULONG ulReason
  26.     , LPVOID pvReserved)
  27.     {
  28.     if (DLL_PROCESS_DETACH==ulReason)
  29.         {
  30.         return TRUE;
  31.         }
  32.     else
  33.         {
  34.         if (DLL_PROCESS_ATTACH!=ulReason)
  35.             return TRUE;
  36.         }
  37.  
  38.     return TRUE;
  39.     }
  40.