home *** CD-ROM | disk | FTP | other *** search
/ The CDPD Public Domain Collection for CDTV 2 / CDPD_II_2352.bin / applications / analyticalc / geted2.cmd < prev    next >
OS/2 REXX Batch file  |  1992-01-01  |  2KB  |  152 lines

  1. RM
  2. ET *X*
  3. CA P#0#0 G0
  4. TE *U HERE
  5. TE R=T
  6. TE S=U-1.
  7. TE P=T
  8. TE Q=S
  9. *C LOOP
  10. *COOP
  11. *CLOOP
  12. L A0
  13. v
  14. %Enter:(F10=Sel,text<Rtn>,arrows,F1=DoCmd,F2=EndCmdProc:%E" %\%
  15. vm
  16. TE B0=41743810560.
  17. DF B0:C0 [F20.1]
  18. L C0
  19. EV *U STRVL A0,1;5
  20. TE *U STRVL A0,1;5
  21. TE C0=%
  22. L E0
  23. EV %=DABS(B0-C0)
  24. TE DABS(B0-C0)\H=%
  25. TE *F NOTUP
  26. L P#_PQ
  27. CA G0 P#0#0
  28. 1
  29. TE *U HERE
  30. TE P=T
  31. TE Q=U-1.
  32. CA P#0#0 G0
  33. DF P#0#0 ['>',F8.2]
  34. TE %=1.
  35. TE *F LOOP
  36. *COTUP
  37. *C NOTUP
  38. *CNOTUP
  39. TE B0=41750102016.
  40. TE %=DABS(B0-C0)
  41. TE *F NOTLFT
  42. L P#_PQ
  43. CA G0 P#0#0
  44. 3
  45. TE *U HERE
  46. TE P=T
  47. TE Q=U-1.
  48. CA P#0#0 G0
  49. DF P#0#0 ['>',F8.2]
  50. TE %=1.
  51. TE *F LOOP
  52. *C NOTLFT
  53. *COTLFT
  54. *CNOTLFT
  55. TE B0=41748004864.
  56. TE %=DABS(B0-C0)
  57. TE *F NOTRGT
  58. L P#_PQ
  59. CA G0 P#0#0
  60. 4
  61. TE *U HERE
  62. TE P=T
  63. TE Q=U-1.
  64. CA P#0#0 G0
  65. DF P#0#0 ['>',F8.2]
  66. TE %=1.
  67. TE *F LOOP
  68. *C NOTRGT
  69. *COTRGT
  70. *CNOTRGT
  71. TE B0=41745907712.
  72. TE %=DABS(B0-C0)
  73. TE *F NOTDWN
  74. L P#_PQ
  75. CA G0 P#0#0
  76. 2
  77. TE *U HERE
  78. TE P=T
  79. TE Q=U-1.
  80. CA P#0#0 G0
  81. DF P#0#0 ['>',F8.2]
  82. TE %=1.
  83. TE *F LOOP
  84. *C NOTDWN
  85. *COTDWN
  86. *CNOTDWN
  87. TE B0=41729097728.
  88. TE %=DABS(B0-C0)
  89. TE *F NOTSEL
  90. *U HERE
  91. L D0
  92. TE U=U-1.
  93. E _@T0,U0
  94. L P#_RS
  95. ED ~~__{D0~
  96. ED /*X*//
  97. TE %=((P-R)*(P-R)+(Q-S)*(Q-S))
  98. TE *F LOOP
  99. CA P#_RS G0
  100. TE %=1.
  101. TE *F LOOP
  102. *C NOTSEL
  103. *COTSEL
  104. *CNOTSEL
  105. TE B0=41712320512.
  106. TE %=DABS(B0-C0)
  107. TE *F NOTENT
  108. L P#_RS
  109. ED /*X*//
  110. CA G0 P#_PQ
  111. TE %=1.
  112. TE *F DONE
  113. *C NOTENT
  114. *COTENT
  115. *CNOTENT
  116. TE B0=41710223360.
  117. TE %=DABS(B0-C0)
  118. TE *F NOTDO
  119. L A0
  120. %Enter command>%%\%
  121. TE %=1.
  122. TE *F LOOP
  123. *C NOTDO
  124. *CNOTDO
  125. *COTDO
  126. L P#_RS
  127. ED ~~__{A0~
  128. ED /*X*//
  129. TE %=((P-R)*(P-R)+(Q-S)*(Q-S))
  130. TE *F LOOP
  131. CA P#_RS G0
  132. TE %=1.
  133. TE *F LOOP
  134. *C Get by keys. This procedure is meant to be mapped to a
  135. *C key in AnalytiCalc (VAX version) to allow "key mode"
  136. *C range locations. You can enter arrow keys, which will have
  137. *C the desired effect of moving you around the sheet, or
  138. *C bits of formulas, which will be entered (you should
  139. *C terminate these by RETURN), or select (VT200 keypad)
  140. *C to enter the "current" cell name into the formula,
  141. *C or ENTER (on auxiliary keypad key) to terminate the
  142. *C formula and enter it.
  143. *C The DO key allows any AnalytiCalc command to be entered.
  144. *C On Amiga, the F2 key works as enter, F1 as DO, and F10 as
  145. *C select.
  146. *CDONE
  147. *C DONE
  148. *CONE
  149. L P#_RS
  150. V
  151. RI
  152.