home *** CD-ROM | disk | FTP | other *** search
/ Corel Draw! Unleashed / Corel Draw! Unleashed.iso / wincim / scripts.lib / DATEXJ.SCR < prev    next >
Encoding:
Text File  |  1993-05-14  |  1.1 KB  |  61 lines

  1. !
  2. !  Copyright (c) 1993
  3. !  by CompuServe Incorporated, Columbus, Ohio
  4. !
  5. !  The information in this software is subject to change without
  6. !  notice and should not be construed as a commitment by CompuServe.
  7. !
  8. !  Datex-J (BTX):
  9. !    Success:  returns %Success
  10. !    Failure:  saves error msg in %FailureMsg and returns %Failure
  11. !
  12. !+V
  13. ! "3.0"
  14. !-V
  15.  
  16. Tries = 5;
  17. on cancel goto Return_Cancel;
  18. show "Connecting to Datex-J";
  19.  
  20. Wait_DatexJ:
  21.     if Tries = 0 goto DatexJ_Failure;
  22.     Tries = Tries - 1;
  23.     wait
  24.         "^@"        goto Send_Response,
  25.         "kennung"    goto Send_Kennung
  26.     until 200;
  27.  
  28.     goto Wait_DatexJ;
  29.  
  30. Send_Response: 
  31.     send "." & %CR;
  32. Send_Kennung:
  33.     wait until 100;         
  34.     send "000255975978";
  35.     show "Sending Datex-J User ID number";
  36. Send_CR:
  37.     wait 
  38.         "DM"        goto Send_Pound,
  39.         "Host Name:"    goto Return_Success
  40.     until 300;
  41.  
  42. Send_Pound:  
  43.     wait until 10;
  44.     send %CR;
  45.     wait until 10;
  46.     send %CR;
  47.     wait until 10;
  48.     send %CR;
  49.     goto Send_CR;
  50.  
  51. DatexJ_Failure:
  52.     define %FailureMsg = "Datex-J not responding";
  53.     exit %Failure;
  54.  
  55. Return_Cancel:
  56.     exit %Cancel;
  57.  
  58. Return_Success:
  59.     send %CR;
  60.     exit %Success;
  61.