According to Orlando Llanes:
@samp{ParamCount} returns the number of command-line arguments seperated by spaces
^^^^^^^^^^^^^^^^^^^ Misleading. A UNIX shell can even pass parameters *containing* spaces when they are surrounded by quotation marks or such.
present after the program is executed.
Also misleading: This sounds for me as if the parameters aren't present until the program has finished.
@samp{ParamCount} returns 0 <1?>
0.
if the only statement on the command-line is the name of the program.
This implies that you are invoking the program from a command line. It can also be invoked from another program, in particular a GUI. I suggest the following: @c ---------------------------------------------------------------------------- @node ParamCount @unnumberedsec ParamCount @cindex ParamCount @unnumberedsubsec Syntax @smallexample Function ParamCount: Integer; @end smallexample @unnumberedsubsec Description @samp{ParamCount} returns the number of command-line arguments given to the program. @samp{ParamCount} returns 0 if no arguments have been given to the program; the name of the program as an implicit argument is not counted. @unnumberedsubsec Standards @samp{ParamCount} is a Borland Pascal extension. @unnumberedsubsec Example @example Program Test; Var i: Integer; begin writeln ( 'You have invoked this program with ', ParamCount, ' arguments.' ); writeln ( 'These are:' ); for i:= 1 to ParamCount do writeln ( ParamStr ( i ) ); end. @end example @unnumberedsubsec See also @ref{ParamStr}. @c ---------------------------------------------------------------------------- Greetings, Peter -- Peter Gerwinski, Essen, Germany, http://home.pages.de/~Peter.Gerwinski/ Maintainer GNU Pascal - http://home.pages.de/~GNU-Pascal/ - gpc-980511 PGP key on request - 6C 94 45 BE 28 A4 96 - 0E CC E9 12 47 25 82 75 Fight the SPAM and UBE! - http://spam.abuse.net/ - http://maps.vix.com/