The Else keyword is part of the If, Case and Try statements. It is used to start the section of code executed when earlier conditions are not satisfied.
See details of each of these statements for further details.
|A mechanism for acting upon different values of an Ordinal
|Keyword that terminates statement blocks
|Starts a conditional expression to determine what to do next
|Part of an if statement - starts the true clause
|Starts code that has error trapping
| Download this web site as a Windows program.
|Example code : Illustrate various uses of the else clause
// Note the lack of a ';' after the 'then' clause
// Nested if statements - Delphi sensibly manages associations
if true then
if false then
ShowMessage('Inner then satisfied')
ShowMessage('Inner else satisfied')
ShowMessage('Outer else satisfied')
|Show full unit code
Inner else satisfied