home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / PASCAL / MADTRB11.ZIP / PARAMS.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1985-07-13  |  670 b   |  24 lines

  1. PROGRAM Params;
  2.  
  3. {
  4. Source: "Programming Quickies", TUG Lines Volume I, Issue 1
  5. Author: Paul Klarreich
  6. Application: IBM PC and true compatibles
  7.  
  8.      Find the parameter string.  In any MS-DOS program file, it is
  9.      found at offset $80 in the program segment prefix -- the first
  10.      $100 bytes of the program segment.  The byte at $80 gives the
  11.      length of the string and the next <length> bytes are the actual
  12.      characters.
  13.  
  14.      Note: This program is meaningless unless compiled to a COM-file.
  15. }
  16.  
  17. VAR  CmdStr : STRING[80] ABSOLUTE CSEG:$0080;
  18.  
  19. BEGIN
  20.  WRITELN('The command tail for this program is:');
  21.  WRITELN('-->',CmdStr,'<--');
  22. END.
  23.  
  24.