home *** CD-ROM | disk | FTP | other *** search
/ Best Objectech Shareware Selections / UNTITLED.iso / boss / word / text / 010 / go.bat < prev    next >
DOS Batch File  |  1993-04-08  |  4KB  |  156 lines

  1. ECHO OFF
  2. :begin
  3. if exist %1 goto fileexists
  4. TED UNNAMED.TXT
  5. IF ERRORLEVEL 10 goto quit
  6. IF ERRORLEVEL 8 goto viewtam1
  7. IF ERRORLEVEL 7 goto printam
  8. goto quit
  9. :fileexists
  10. TED %1
  11. IF ERRORLEVEL 10 goto quit
  12. IF ERRORLEVEL 8 goto viewtam2
  13. IF ERRORLEVEL 7 goto printam
  14. goto quit
  15. :viewtam1
  16. T UNNAMED.TXT TEMP.TAM O
  17. goto viewtam
  18. :viewtam2
  19. T %1 TEMP.TAM O
  20. :viewtam
  21. P TEMP.TAM ATI
  22. goto begin
  23. :printam
  24. CLS
  25. ECHO    ─────────────────────────────────────────────────────────────────────
  26. ECHO    ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  27. ECHO                ┌────────────────────┐
  28. ECHO                │  HARD COPY OPTIONS │
  29. ECHO                └────────────────────┘
  30. ECHO        The file you last viewed will be printed.
  31. ECHO You should have already viewed the file you are going to print.
  32. ECHO        If not press Q to return to the editor.
  33. ECHO    ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  34. ECHO        E - Epson /IBM Dot matrix printer
  35. ECHO        C - Color Dot matrix printer
  36. ECHO        H - HP Laser printer
  37. ECHO        Q - Quit
  38. CHOOSE 7            Type E, C, H or Q:
  39. IF ERRORLEVEL 113 goto begin
  40. IF ERRORLEVEL 104 goto hplaser
  41. IF ERRORLEVEL 101 goto epson
  42. IF ERRORLEVEL 99 goto colord
  43. IF ERRORLEVEL 81 goto begin
  44. IF ERRORLEVEL 72 goto hplaser
  45. IF ERRORLEVEL 69 goto epson
  46. IF ERRPRLEVEL 67 goto colord
  47. goto printam
  48. :hplaser
  49. CLS
  50. ECHO    ─────────────────────────────────────────────────────────────────────
  51. ECHO    ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  52. ECHO                ┌────────────────────┐
  53. ECHO                │  HPLASER OPTIONS   │
  54. ECHO                └────────────────────┘
  55. ECHO        P - Parellel Port
  56. ECHO        F - Print to file
  57. ECHO        1 - Serial port COM1
  58. ECHO        2 - Serial port COM2
  59. ECHO        Q - Quit
  60. CHOOSE 7            Type P, F, 1, 2, Q:
  61. IF ERRORLEVEL 113 goto printam
  62. IF ERRORLEVEL 112 goto hparellel
  63. IF ERRORLEVEL 102 goto temphpl
  64. IF ERRORLEVEL 81 goto printam
  65. IF ERRORLEVEL 80 goto hparellel
  66. IF ERRORLEVEL 70 goto temphpl
  67. IF ERRORLEVEL 50 goto hserial2
  68. IF ERRORLEVEL 49 goto hserial1
  69. goto hplaser
  70. :hserial1
  71. MODE COM1:9600,n,8,1,p
  72. MODE LPT1=COM1
  73. goto hparellel
  74. :hserial2
  75. MODE COM2:9600,n,8,1,p
  76. MODE LPT1=COM2
  77. :hparellel
  78. P TEMP.TAM hplaser PRN
  79. goto begin
  80. :temphpl
  81. P TEMP.TAM hplaser
  82. goto begin
  83. :epson
  84. CLS
  85. ECHO    ─────────────────────────────────────────────────────────────────────
  86. ECHO    ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  87. ECHO                ┌──────────────────────┐
  88. ECHO                │  DOT MATRIX OPTIONS  │
  89. ECHO                └──────────────────────┘
  90. ECHO        P - Parellel Port
  91. ECHO        F - Print to file
  92. ECHO        1 - Serial port COM1
  93. ECHO        2 - Serial port COM2
  94. ECHO        Q - Quit
  95. CHOOSE 7            Type P, F, 1, 2, Q:
  96. IF ERRORLEVEL 113 goto printam
  97. IF ERRORLEVEL 112 goto eparellel
  98. IF ERRORLEVEL 102 goto tempeps
  99. IF ERRORLEVEL 81 goto printam
  100. IF ERRORLEVEL 80 goto eparellel
  101. IF ERRORLEVEL 70 goto tempeps
  102. IF ERRORLEVEL 50 goto eserial2
  103. IF ERRORLEVEL 49 goto eserial1
  104. goto epson
  105. :eserial1
  106. MODE COM1:9600,n,8,1,p
  107. MODE LPT1=COM1
  108. goto eparellel
  109. :eserial2
  110. MODE COM2:9600,n,8,1,p
  111. MODE LPT1=COM2
  112. :eparellel
  113. P TEMP.TAM epson PRN
  114. goto begin
  115. :tempeps
  116. P TEMP.TAM epson
  117. goto begin
  118. :colord
  119. CLS
  120. ECHO    ─────────────────────────────────────────────────────────────────────
  121. ECHO    ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  122. ECHO            ┌────────────────────────────┐
  123. ECHO            │  COLOR DOT MATRIX OPTIONS  │
  124. ECHO            └────────────────────────────┘
  125. ECHO        P - Parellel Port
  126. ECHO        F - Print to file
  127. ECHO        1 - Serial port COM1
  128. ECHO        2 - Serial port COM2
  129. ECHO        Q - Quit
  130. CHOOSE 7            Type P, F, 1, 2, Q:
  131. IF ERRORLEVEL 113 goto printam
  132. IF ERRORLEVEL 112 goto cparellel
  133. IF ERRORLEVEL 102 goto ctempeps
  134. IF ERRORLEVEL 81 goto printam
  135. IF ERRORLEVEL 80 goto cparellel
  136. IF ERRORLEVEL 70 goto ctempeps
  137. IF ERRORLEVEL 50 goto eserial2
  138. IF ERRORLEVEL 49 goto eserial1
  139. goto colord
  140. :eserial1
  141. MODE COM1:9600,n,8,1,p
  142. MODE LPT1=COM1
  143. goto cparellel
  144. :eserial2
  145. MODE COM2:9600,n,8,1,p
  146. MODE LPT1=COM2
  147. :cparellel
  148. P TEMP.TAM color PRN
  149. goto begin
  150. :ctempeps
  151. P TEMP.TAM color
  152. goto begin
  153. :quit
  154. CLS
  155. TYPE ADAMI.MSG
  156.