home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 11 Util / 11-Util.zip / ftaskbar.zip / tinstal.cmd < prev    next >
OS/2 REXX Batch file  |  1995-10-16  |  2KB  |  62 lines

  1. /*
  2.  * FM/2 Taskbar installation program
  3.  */
  4. '@Echo off'
  5. 'cls'
  6. /* tell the nice people who we are */
  7. say ''
  8. say ' ┌────────────────────────────────────────────────────────────────────────────┐'
  9. say ' │                                                                            │'
  10. say ' │                     FM/2 Taskbar installation program                      │'
  11. say ' ├────────────────────────────────────────────────────────────────────────────┤'
  12. say ' │   FM/2, FM/2 Utilities, and FM/2 Taskbar copyright (c) 1995 by M. Kimes    │'
  13. say ' │                             all rights reserved                            │'
  14. say ' │                                                                            │'
  15. say ' └────────────────────────────────────────────────────────────────────────────┘'
  16. say ''
  17. /* get current directory */
  18. curdir = directory()
  19. /* see if we have what we need to run */
  20. rc = stream('taskhook.dll','c','query exists')
  21. if rc = '' then
  22. do
  23.   say 'Sorry, TASKHOOK.DLL not found.  Must not be right directory.  Terminating.'
  24.   exit
  25. end
  26. rc = stream('taskbar.exe','c','query exists')
  27. if rc = '' then
  28. do
  29.   say 'Sorry, TASKBAR.EXE not found.  Must not be right directory.  Terminating.'
  30.   exit
  31. end
  32. /* load system utility functions */
  33. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  34. call SysLoadFuncs
  35. /* ask where they want the program object */
  36. call charout ,"Create object on [D]esktop or in [S]tartup folder? [D/S] "
  37. /* get input */
  38. dummy = ''
  39. do forever
  40.   dummy = SysGetKey('NOECHO')
  41.   parse upper var dummy dummy
  42.   if dummy = 'D' then leave
  43.   if dummy = 'S' then leave
  44. end
  45. /* got input; echo it */
  46. call charout ,dummy
  47. say ''
  48. /* now do it */
  49. if dummy = 'D' then location = '<WP_DESKTOP>'
  50. if dummy \= 'D' then location = '<WP_START>'
  51. title = 'FM/2 Taskbar'
  52. classname = 'WPProgram'
  53. setup = 'OBJECTID=<FM/2 Taskbar>;EXENAME='curdir'\TASKBAR.EXE;STARTUPDIR='curdir';PARAMETERS=%'
  54. rc = SysCreateObject(classname,title,location,setup,u)
  55. if rc = 0 then
  56. do
  57.   call SysDestroyObject "<FM/2 Taskbar>"
  58.   call SysCreateObject classname,title,location,setup,u
  59. end
  60. /* tell the nice people that we're done and how to run it */
  61. say 'FM/2 taskbar installation complete.  Start with WPS object when ready.'
  62.