home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 2434 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  2.3 KB

  1. Path: informatik.tu-muenchen.de!ganterth
  2. From: ganterth@mathematik.tu-muenchen.de (Thomas Ganter)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: BatchFile Params
  5. Date: 31 Jan 1996 13:09:19 GMT
  6. Organization: Math. Institut der TU Muenchen
  7. Distribution: world
  8. Message-ID: <1996Jan31.140919@mathematik.tu-muenchen.de>
  9. References: <DM1KJo.7z4@info.swan.ac.uk>
  10. NNTP-Posting-Host: sunbulirsch11.mathematik.tu-muenchen.de
  11. X-newsreader: xrn 7.00
  12. To: cs9h3kmk@Swansea.ac.uk
  13.  
  14. In article <DM1KJo.7z4@info.swan.ac.uk>, your.E-Mail.name@Swansea.ac.uk (Your Name Here) writes:
  15. |> Hi there,
  16. |> 
  17. |> can somebody please tell me how to pass command line parameters into
  18. |> a batch file
  19. |> 
  20. |> For example on the PC, the first parameter is %1, 2nd is %2 etc...
  21. |> (BUT HOW DO YOU DO THIS ON THE AMIGA???)
  22.  
  23. Ever heard of .KEY? I have. I'm not that big a scripter, but here is
  24. what I recall from what I read in the Manuals:
  25.  
  26. It's much simpler and more flexible than anything you can do on PCs.
  27. You simply make the first line of your Script ".KEY " followd by a
  28. standard ReadArgs()-Style parameter description (although i seem to
  29. recall that there are problems with \M), and then refer to the
  30. Arguments via "(NAME)". You can redefine the Brackets using the
  31. .BRA and .KET directive. You also can give Strings to be used
  32. as default using "(NAME$default)" and lots more. 
  33.  
  34. Refer to the AmigaDOS Manual for defails. The things I explained I wrote
  35. from memory, so there is no guarantee that i have everything right.
  36.  
  37. |> This would make my life a hell of a lot easier if there is a way,
  38. |> 
  39. |> I've tried $1,$2, etc
  40. |> 
  41.  
  42.  
  43.                         - Thomas
  44.  
  45. ------------------------------------------------------------------------------
  46.   Thomas Ganter            Student der Mathematik
  47.   Postweg 3            email: ganterth@mathematik.tu-muenchen.de
  48.   83209 Prien am Chiemsee    FAX  : (0) 8051 - 63179
  49.   Bavaria, Germany        Phone: (0) 8051 - 61895 & 62054
  50. ------------------------------------------------------------------------------
  51.   Amiga Developer (ETG 249)  -  A3000/14Megs/550MB HD/PicassoII
  52. ------------------------------------------------------------------------------
  53.  
  54.   Mathematicians are like Frenchmen: whenever you say something to them,
  55.   they translate it into their own language, and at once it is something
  56.   entirely different.                     J. W. v. Goethe
  57.  
  58.