home *** CD-ROM | disk | FTP | other *** search
/ Aminet 18 / aminetcdnumber181997.iso / Aminet / dev / c / CLib37x.lha / c_lib / source / test_prg / TestExampleLib.c < prev    next >
Encoding:
C/C++ Source or Header  |  1996-12-05  |  673 b   |  39 lines

  1. /*
  2. **      $VER: TextExampleLib.c 37.1 (4.12.96)
  3. **
  4. **      Demo program for example.library
  5. **
  6. **      (C) Copyright 1996 Andreas R. Kleinert
  7. **      All Rights Reserved.
  8. */
  9.  
  10. #include <exec/types.h>
  11. #include <exec/memory.h>
  12.  
  13. #include <example/example.h>
  14.  
  15. #include <proto/exec.h>
  16. #include <proto/example.h>
  17.  
  18. #include <stdio.h>
  19. #include <stdlib.h>
  20.  
  21.  
  22. void main(long argc, char **argv)
  23. {
  24.  struct ExampleBase *ExampleBase = NULL;
  25.  
  26.  ExampleBase = (APTR) OpenLibrary("example.library", 37);
  27.  if(ExampleBase)
  28.   {
  29.    EXF_TestRequest("Test Message", "It works!", "OK");
  30.  
  31.    CloseLibrary((APTR) ExampleBase);
  32.  
  33.    exit(0);
  34.  
  35.   }else printf("\nLibrary opening failed\n");
  36.  
  37.  exit(20);
  38. }
  39.