home *** CD-ROM | disk | FTP | other *** search
/ Computer Buyer 1995 September / C_BUYER.ISO / dosshare / finnish / install.fil < prev    next >
Text File  |  1993-03-12  |  14KB  |  399 lines

  1. ' Sample Install Script for
  2. ' The Finishing Touch
  3. ' Professional Software Installer
  4. ' Copyright 1992, ImagiSOFT, Inc.
  5. ' March 12, 1993
  6.  
  7. ' NOTE:  This script file takes a LONG TIME to load because INSTALL.EXE
  8. '        does a CRC check of the documentation files before proceeding.
  9. '        The registered version does NOT do this.
  10.  
  11. '        There is a 400 line maximum for any one script file.  However,
  12. '        this limitation can be overcome by using the SCRIPT command.
  13.  
  14. '        This script file doesn't use all the possible commands.
  15. '        See the documentation for the commands to check hardware,
  16. '        perform conditional jumps, view ASCII files, run or shell
  17. '        to DOS programs, change AUTOEXEC.BAT and CONFIG.SYS,
  18. '        invoke other script files, and more!
  19.  
  20. BACKGROUND 63    ' display cyan colored background (see color chart in docs)
  21.  
  22. LANGUAGE ENGLISH
  23. ' French, German, and Spanish are also supported.  English is the default
  24. ' so this command is used as an example only.
  25.  
  26. BORDER 1                                   ' single line borders. 2 = double, 0 = no border
  27.  
  28. TELESCOPE OFF
  29. ' turn off "exploding" or telescoping windows for first window
  30. ' this will make the window instantly appear
  31.  
  32.  
  33. ' display the heading in a window
  34. '   located at 18 characters across
  35. '               2 rows down  with a
  36. '   magenta background and high intensity white letters  (see color chart)
  37.  
  38. WINOPEN 18 2 95
  39.  
  40. "            ImagiSOFT, Inc."
  41. "Where Imagination Brings Software to Life "
  42. ""
  43. ""
  44. ""
  45. ""
  46. ""
  47.  
  48. ' WINOPEN 0 2 95             ' use this command instead to make sure the
  49.                              ' window is centered horizontally on the screen
  50.  
  51. ' another nice feature is the ability to write text in a different color
  52. ' within a window.  Most commands can use relative cursor positions, as
  53. ' shown in this example:
  54. PAUSE 100
  55. WINUPDATE +13 +4 94
  56. "THE FINISHING TOUCH"        ' yellow text
  57.                              ' 13 characters across
  58.                              ' and 4 rows down
  59.                              ' from the upper left hand corner of the window
  60. PAUSE 50                     ' 1/2 second delay between words
  61. WINUPDATE +2 +5 95
  62. "Professional Software Installation Program"
  63. PAUSE 50
  64. WINUPDATE +17 +6 95
  65. "Version 2.4"
  66. PAUSE 50
  67. WINUPDATE +16 +7 95
  68. "March 12, 1993"
  69. PAUSE 300                     ' 3 second delay
  70.  
  71. TELESCOPE ON       ' turn on telescoping windows for the rest of the messages
  72.  
  73. SHADOW ON
  74. ' display all messages from this point on in a "shadowed" window
  75. ' the default is "OFF".  This feature can be turned on and off as many
  76. ' times as you want
  77.  
  78. WINOPEN 0 12 31
  79. "THE FINISHING TOUCH WILL SAVE YOU MONEY BY . . .       "
  80. ""
  81. ""
  82. ""
  83. ""
  84. ""
  85. ""
  86. ""
  87. WINUPDATE +36 +1 26
  88. "MONEY"
  89. PAUSE 300                                   ' 3 seconds
  90. WINUPDATE +2 +3 30
  91. "■ Cutting the number of disks in your program in half."
  92. "  (see the UNPACK command and PACKER utility)"
  93. BEEP
  94. PAUSE 200
  95. WINUPDATE +2 +3 31
  96. "■ Cutting the number of disks in your program in half."
  97. "  (see the UNPACK command and PACKER utility)"
  98. WINUPDATE +2 +6 30
  99. "■ Reducing your installation support problems."
  100. BEEP
  101. PAUSE 200
  102. WINUPDATE +2 +6 31
  103. "■ Reducing your installation support problems."
  104. WINUPDATE +2 +8 30
  105. "Press the [Enter] key to continue."
  106. WAIT +36 +8                                ' wait for the enter key
  107. WINCLOSE                                   ' close the window
  108.  
  109. WINOPEN 0 12 31
  110. ""
  111. " ■ Is Rich with Powerful Features"
  112. ""
  113. " ■ Is Easy to Learn"
  114. "   (Look at INSTALL.FIL for this script)"
  115. ""
  116. " ■ Can be as simple or complex as you want "  ' widest message determines width
  117. ""
  118. WINUPDATE +4 +0 31
  119. "┤"
  120. WINUPDATE +41 +0 31
  121. "├"
  122. WINUPDATE +5 +0 30
  123. "        THE FINISHING TOUCH         "
  124. WINUPDATE +4 +9 31                         ' write on top of bottom border
  125. "┤ Press the [Enter] key to continue ├"    ' (good when space is tight)
  126. WINUPDATE +16 +9 30
  127. "[Enter]"
  128. WAIT +39 +9                                ' wait for the enter key
  129. WINCLOSE                                   ' close the window
  130.  
  131. WINOPEN 0 12 31
  132. "This sample installation file will demonstrate some of"
  133. "THE FINISHING TOUCH'S features by installing a FREE"
  134. "file date and time stamping utility."
  135. ""
  136.  
  137. WINUPDATE +49 +2 27                        ' change the color of
  138. "FREE"                                     ' the word "free" to cyan
  139.  
  140. WINUPDATE +9 +5 31                         ' write on top of bottom border
  141. "┤ Press the [Enter] key to continue ├"    ' (good when space is tight)
  142.  
  143. WINUPDATE +21 +5 30                        ' yellow text
  144. "[Enter]"
  145.  
  146. WAIT +44 +5                                ' wait for the enter key
  147. WINCLOSE                                   ' close the window
  148.  
  149.  
  150. ' Tell INSTALL the minimum amount of required disk space
  151.  
  152. SPACE 7                          ' This sample is tiny, only 7K required.
  153.  
  154.  
  155. '  Prompt for the drive to install to:
  156.  
  157. DRIVE C 0 12 31 15 32 14 79
  158. '         C = drive C, the pre-stuffed drive letter
  159. '         0 = center window horizontally
  160. '        12 =              and  12  rows down
  161. '        31 = blue background and high intensity white foreground
  162. '        15 = input on a black background w/ high intensity white letters
  163. '        32 = error message located at 32 characters across
  164. '        14 =                      and 14 rows down
  165. '        79 = any error message will appear in a red window with
  166. '             high intensity white letters
  167.  
  168. ' After  the user selects a drive and presses [Enter], the first  thing
  169. ' the  DRIVE command does is make sure the drive exists.  Next it  will
  170. ' check  for the required disk space.  If the drive does not exist,  or
  171. ' there is not enough space, an error message appears, and the user  is
  172. ' required to pick a different drive, or quit.
  173.  
  174.  
  175. ' Prompt with default path \SAMPLE
  176.  
  177. ' INSTALL.EXE  will work the same way whether the user enters SAMPLE,
  178. ' \SAMPLE\, or \SAMPLE.  Mutiple directories such as \SAMPLE\UTIL\FREE
  179. ' are also supported.
  180.  
  181. PATH \SAMPLE 0 12 31 15 32 14 79
  182.  
  183. ' the numbers above represent window locations and colors.  See the
  184. ' documentation for more details
  185.  
  186. '  Unpack the files from the floppy drive.
  187.  
  188. UNPACK SAMPLE.PAK 0 12 31 32 14 79
  189. ' SAMPLE.PAK was compressed using the enclosed PACKER utility.  This
  190. ' utility will compress files 50% or more depending on the file type.
  191. ' you should get compression results close to that of PKZIP.
  192. ' the numbers above represent window locations and colors.  See the
  193. ' documentation for more details
  194.  
  195. ' just for fun, open the disk drive right in the middle of the installation
  196. ' and see what happens.  This is only one of four "jump" commands supported.
  197. ' see the documentation for JUMP, JUMP.NO, and JUMP.YES commands.
  198.  
  199. JUMP.FAIL INSTALL_FAILURE
  200.  
  201. WINOPEN 0 12 31
  202.  
  203. "A FREE file stamping utility has been installed on your"
  204. "computer in the directory"
  205. ""
  206. "This is our way of saying THANKS for taking the time to"
  207. "review the THE FINISHING TOUCH!"
  208. ""
  209. "Press the [Enter] key to continue."
  210.  
  211. WINUPDATE +28 +2 30                       ' display text in yellow
  212. "~1~2."
  213.  
  214. WINUPDATE +28 +4 27                       ' cyan
  215. "THANKS"
  216.  
  217. WAIT +36 +7
  218. ' Wait for the user to press the [Enter] key so they can
  219. ' read the above window.
  220. ' The plus signs denote that you want the cursor located relative to
  221. ' the upper left hand corner of the window (position 0, 0) 7 rows down
  222. ' and 36 characters across.
  223.  
  224. WINCLOSE                         ' close the above window
  225.  
  226. ' ------------------------------------------------------
  227. ' Ask user if they would like to view the utility's docs
  228. ' ------------------------------------------------------
  229. WINOPEN 0 12 31
  230. "Would you like to see the new utility's documentation?"
  231. ""                            ' this is necessary so that the winupdate
  232.                               ' command will have some place to display the
  233.                               ' (Y or N)
  234.  
  235. WINUPDATE +25 +2 30           ' yellow text
  236. "(Y or N)"
  237.  
  238. ASK +33 +2                    ' one method of providing a "conditional" jump
  239.                               ' note relative cursor positioning
  240.  
  241. WINCLOSE                      ' close the above window
  242.  
  243. JUMP.NO VIEW_INSTALL.TXT      ' skip the view command if the user
  244.                               ' hits the "N" key from the above
  245.                               ' ASK statement.
  246.  
  247. VIEW ~1~2\STAMP.TXT 79 31     ' as you can see, The Finishing Touch
  248.                               ' has a built-in file viewer
  249.  
  250. ' -----------------------------------------------------
  251. ' Ask user if they would like to view the documentation
  252. ' -----------------------------------------------------
  253. :VIEW_INSTALL.TXT
  254. WINOPEN 0 12 31
  255. "Would you like to SEE the documentation for THE FINISHING TOUCH?"
  256. ""
  257.  
  258. WINUPDATE +31 +2 30            ' yellow text
  259. "(Y or N)"
  260.  
  261. ASK +39 +2                     ' one method of providing a "conditional" jump
  262.                                ' again, relative cursors are easier
  263.  
  264. WINCLOSE                       ' close the above window
  265.  
  266. JUMP.NO PRINT_INSTALL.TXT      ' again, skip the view command if the user
  267.                                ' hits the "N" key from the above ASK statement.
  268.  
  269. WINOPEN 0 0 31                ' large file takes a while from floppy ...
  270. "Loading 67 Pages ..."
  271. VIEW ~0\INSTALL.TXT 79 31
  272. WINCLOSE                      ' close the above window
  273.  
  274. ' -------------------------------------------------------
  275. ' Ask user if they would like to print the documentation
  276. ' -------------------------------------------------------
  277. :PRINT_INSTALL.TXT
  278. WINOPEN 0 12 31
  279. "Would you like to PRINT the documentation for THE FINISHING TOUCH?"
  280. ""
  281.  
  282. WINUPDATE +31 +2 30           ' yellow text
  283. "(Y or N)"
  284.  
  285. ASK +39 +2                    ' one method of providing a "conditional" jump
  286.  
  287. WINCLOSE                      ' close the above window
  288. JUMP.NO EXIT
  289.  
  290. WINOPEN 0 0 31                ' printing large file takes a while ...
  291. ""
  292. "  Printing 67 Pages ...  "
  293. ""
  294. PRINT ~0\INSTALL.TXT
  295. WINCLOSE                      ' close the above window
  296. JUMP.FAIL PRINTER_ERROR       ' jump on fatal error
  297. JUMP EXIT                     ' print successful, skip next
  298.  
  299. :PRINTER_ERROR                ' label for error condition
  300. WINOPEN 0 12 79                ' open the following window
  301. "Your printer is not responding.  Possible problems:"
  302. "   -- Printer is not turned on"
  303. "   -- Printer is out of paper"
  304. "   -- Printer is not attached to LPT1 (parallel port 1)"
  305. ""
  306. "Do you want to try to print again  (Y or N)?"
  307. ASK 57 18                     ' prompt for Y or N key  (fixed cursor position)
  308. WINCLOSE                      ' close this window
  309. JUMP.YES PRINT_INSTALL.TXT    ' y key pressed, print
  310.  
  311. ' ----------------------
  312. ' display closing window
  313. ' ----------------------
  314. :EXIT
  315.  
  316. WINOPEN 0 12 31                ' window is centered on screen
  317. "Thank you for running the installation demonstration for the"
  318. ""
  319. "                   THE FINISHING TOUCH"
  320. "          The Professional Installation Program"
  321. ""
  322. "You have a fully working shareware evaluation copy.  We hope"
  323. "that you will find THE FINISHING TOUCH is the most powerful,"
  324. "smallest, easiest to use, software installer with the best"
  325. "file compression available anywhere.  ENJOY!"
  326. ""
  327.  
  328. WINUPDATE +21 +3 30
  329. "THE FINISHING TOUCH"                   ' yellow text
  330. WINUPDATE +40 +9 27
  331. "ENJOY!"                                ' cyan text
  332. WINUPDATE +12 +11 31                     ' write on top of bottom border
  333. "┤ Press the [Enter] key to continue ├"    ' (good when space is tight)
  334. WINUPDATE +24 +11 30
  335. "[Enter]"
  336. WAIT +47 +11
  337. WINCLOSE
  338.  
  339. ' display our bbs phone number
  340. BORDER 2                                ' double line borders supported
  341.                                         ' for no border, use BORDER 0
  342. WINOPEN 0 12 110
  343. "If you're not sure you have the latest shareware copy of"
  344. "THE FINISHING TOUCH, call Software Creations BBS our home BBS:"
  345. ""
  346. ""
  347. ""
  348. ""
  349. ""
  350. ""
  351. ""
  352. "Press the [Enter] key to continue."
  353.  
  354. WINUPDATE +28 +2 107
  355. "Software Creations BBS"
  356. WINUPDATE +13 +4 106
  357. "33 Lines to Serve You 24 Hours per Day!"
  358. WINUPDATE +14 +5 111                         ' you can winupdate more than
  359. "(508) 365-2359        2400 baud"            ' one line at a time
  360. "(508) 368-4137        2400-14.4K USR"
  361. "(508) 368-7036        2400-14.4K V.32"
  362. WAIT +36 +10                                  ' wait for the enter key
  363.  
  364. ' ------------------------
  365. ' exit the system normally
  366. ' ------------------------
  367. END
  368.  
  369. ' ---------------------------------------------------
  370. ' Installation Failure. It is a good idea to add a
  371. ' similar routine to the bottom of all script files.
  372. ' ---------------------------------------------------
  373. :INSTALL_FAILURE
  374.  
  375. WINOPEN 0 12 79
  376. "THE INSTALLATION PROGRAM FAILED PRIOR TO COMPLETION"
  377. ""
  378. "Possible reasons:"
  379. "   -- The floppy disk was removed prior to completion."
  380. "   -- The floppy disk was damaged during shipping."
  381. "   -- Your disk drive is out of alignment."
  382. ""
  383. "Press [Enter] to remove incomplete program files."
  384. WAIT 62 20
  385.  
  386. ' delete all partial files using internal variables
  387. '   ~1 = the drive the user installed to (C: was the default)
  388. '   ~2 = the path the user installed to (\SAMPLE was the default)
  389. DELETE ~1~2\*.* 0 0 31
  390.  
  391. ' now remove the directory
  392. RD ~1~2
  393. WINCLOSE
  394. WINOPEN 0 12 31
  395. "Partially Installed Files are Now Deleted."
  396. ""
  397. "      Press [Enter] to Quit."
  398. WAIT 47 15
  399.