home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / amiga / programm / 11685 < prev    next >
Encoding:
Internet Message Format  |  1992-07-27  |  1.7 KB

  1. Path: sparky!uunet!sun-barr!cs.utexas.edu!uwm.edu!rutgers!cbmvax!mks
  2. From: mks@cbmvax.commodore.com (Michael Sinz)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: Using System() when started from Workbench -- path?
  5. Message-ID: <33697@cbmvax.commodore.com>
  6. Date: 27 Jul 92 14:12:34 GMT
  7. References: <0ePirjO00WB6AL40NI@andrew.cmu.edu> <paulk.0wj4@terapin.com>
  8. Reply-To: mks@cbmvax.commodore.com (Michael Sinz)
  9. Organization: Commodore, West Chester, PA
  10. Lines: 24
  11.  
  12. paulk@terapin.com (Paul Kienitz) writes:
  13. >> Does someone have a simple example of getting the path from the
  14. >> Workbench process so I can feed it to System()?
  15. >
  16. >My program CLImax does this, though it's a 1.3-ish program.  Lemme
  17. >look at the source ...
  18.  
  19. Watch out... You really do not want to use FindTask("Workbench")
  20. to find the workbench task.  If you look at the startup message
  21. and look at the reply port and find out that there is a PA_SIGNAL
  22. then get the PA_SIGTASK pointer to find the task.  This way, if
  23. someone wants to do a replacement workbench or a different tool
  24. started, it will work.
  25.  
  26. Also, you need to watch out that you don't hang up for too long
  27. since workbench may start playing with its path while you are.
  28.  
  29. /----------------------------------------------------------------------\
  30. |      /// Michael Sinz  -  Senior Amiga Systems Engineer              |
  31. |     ///                   Operating System Development Group         |
  32. |    ///   BIX:  msinz      UUNET:  mks@cbmvax.commodore.com           |
  33. |\\\///                     When people are free to do as they         |
  34. | \XX/                      please, they usually imitate each other.   |
  35. \----------------------------------------------------------------------/
  36.