TCustomApplication.HasOption function
Check whether an option was specified.
Declaration
function HasOption(const S: string): Boolean
function HasOption(const C: char; const S: string): BooleanArguments
S | Long option string. |
C | Short option character. |
Function result
True if the option
S or
C was
specified on the command-line.Description
HasOption returns
True if the specified option
was given on the command line. Either the short option character
C or the long option
S may be used. Note that both
options (requiring a value) and switches can be specified.
Depending on the value of the CaseSensitiveOptions property, the search is performed case sensitive or case insensitive.
Options are identified as command-line parameters which start with OptionChar (by default the dash ('-') character).
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
