home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 2 BBS / 02-BBS.zip / orionful.zip / Menus / Login.Cmd < prev    next >
OS/2 REXX Batch file  |  1995-07-28  |  1KB  |  78 lines

  1. /* The Main Menu */
  2.  
  3. ARG line
  4.  
  5. /*
  6.    Below I am defining the return codes for specific control and key
  7.    return codes that AdeptTimedInKey will return
  8. */
  9.  
  10. CTRL_A = 1
  11. CTRL_B = 2
  12. CTRL_C = 3
  13. CTRL_D = 4
  14. CTRL_E = 5
  15. CTRL_F = 6
  16. CTRL_G = 7
  17. CTRL_H = 8
  18. CTRL_I = 9
  19. CTRL_J = 10
  20. CTRL_K = 11
  21. CTRL_L = 12
  22. CTRL_N = 14
  23. CTRL_O = 15
  24. CTRL_P = 16
  25. CTRL_Q = 17
  26. CTRL_R = 18
  27. CTRL_S = 19
  28. CTRL_T = 20
  29. CTRL_U = 21
  30. CTRL_V = 22
  31. CTRL_W = 23
  32. CTRL_X = 24
  33. CTRL_Y = 25
  34. CTRL_Z = 26
  35.  
  36. /*
  37.    Below are the return codes for ANSI, VT100, VT220, and Local keyboard
  38.    entry
  39. */
  40.  
  41. HOME   = 71+1024
  42. UP     = 72+1024
  43. PGUP   = 73+1024
  44. BS     = 75+1024
  45. FWD    = 77+1024
  46. END    = 79+1024
  47. DN     = 80+1024
  48. PGDN   = 81+1024
  49. INS    = 82+1024
  50. DEL    = 83+1024
  51. LEFT   = 75+1024
  52. RIGHT  = 77+1024
  53.  
  54. DisplayTimer = AdeptSetTimer(line, 10)
  55.  
  56. AdeptSleep(line, 64)
  57. CALL SHOWDATA
  58.  
  59. GETKEY:
  60.    KeyIn = AdeptComPeekByte(line, 64)
  61.    KeyIn = AdeptPeekKey(line)
  62.    if(KeyIn > 0) then do
  63.       exit
  64.    end
  65.    CALL SHOWDATA
  66.    AdeptSleep(line, 64)
  67.    SIGNAL GETKEY
  68. return
  69.  
  70. SHOWDATA:
  71.      MyRet = AdeptTimerUp(line, DisplayTimer)
  72.      if MyRet == 1 then
  73.      do
  74.        AdeptPrint(line, "s2H{CR - {D3-{D4-{D2u")
  75.        DisplayTimer = AdeptSetTimer(line, 2000)
  76.      end
  77. return
  78.