Class TCommandLineParser lets developer configure a syntax of command line. VB.NET TCommandLineParser class is almost full clone of the same C++ class (see PARSING COMMAND LINE IN C++). Command line syntax is defined using parameters - building blocks of command line.

Type of command line parameter

Comment

Void Parameter

It is valueless parameter. Sometimes it is called "switch". For example, parameters /help and /debug are examples of void parameter.

Integer Parameter

Used to hold integer value.
/timeout=10 is example of integer parameter which value is integer number 10. There are also two special versions of integer parameter:
- positive integer parameter (accepts only positive integers: 1,2,3,....)
- bounded integer parameter (accepts integers from some range).

String Parameter

Used to hold strings. If string contains spaces it must be quoted. for example, /dir="\Program files\"

Gets integer parameter value. The second optional argument is for number of real command line argument in case of multiple parameter instances. For example,
Dim timeout as Integer = commandline.GetInt("Timeout")