home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 25 / nopv25.iso / 040A / PBL30SAM.ZIP / LANGTEST.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1996-08-08  |  618 b   |  35 lines

  1. #include "prolang.h"
  2. #include "proutil.h"
  3. #include "pblsdk.h"
  4.  
  5. #ifndef PB_SDK
  6.     #include <conio.h>
  7.     #include <alloc.h>
  8. #else
  9.     #include "pblibc.h"
  10. #endif
  11.  
  12. int
  13. main( void )
  14. {
  15.     char ch;
  16. #ifndef PB_SDK
  17.     long em, sm = coreleft();
  18. #endif
  19.     zProLang *lang = new zProLang;
  20.     for( int i = 1; i <= lang->GetNumPrompts() && !lang->Error(); ++i ){
  21.         lang->Exec(i, False);
  22.         while( 0 == (ch = PeekChar()) )
  23.             continue;
  24.         if( 'q' == ch || 'Q' == ch ) break;
  25.         textattr(7);
  26.         clrscr();
  27.     }
  28.     delete lang;
  29. #ifndef PB_SDK
  30.     em = coreleft();
  31.     printf("start: %lx\nend  : %lx\n", sm, em);
  32. #endif
  33.     return 0;
  34. }
  35.