Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Turbo Pascal - <b> paramcount number of parameter in command line pp 144</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 PARAMCOUNT          Number of Parameter in Command Line              pp 144

 Syntax:  ParamCount ;

 Type:    Integer

 Form:    Function

 Purpose: Returns the number of parameters passed to the program in the
          command line.  Spaces and tabs serve as separators.


 ----------------------------------------------------------------------------


 Usage:
       VAR
          IntVar  : Integer                          ; { Integer variable  }
          CmdParm : String [128]                     ; { Parm string       }
          CmdTail : String [128] Absolute Cseg:$0080 ; { Command tail      }

       BEGIN
          IntVar  := ParamCount                      ; { Get parm count    }
          CmdParm := ParamStr (IntVar)               ; { Get last parm     }
          WriteLn (IntVar)                           ; { Display count     }
          WriteLn (CmdParm)                          ; { Display last parm }
          WriteLn (CmdTail)                          ; { Display cmd tail  }
       END.

See Also: Absolute ParamStr

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson