不行,看看case的帮助
The case statement provides a readable alternative to complex nested if conditionals. A case statement has the form
case selectorExpression of
caseList1: statement1;
...
caseListn: statementn;
end
[red]where selectorExpression is any expression of an ordinal type (string types are invalid) [/red]and each caseList is one of the following:
A numeral, declared constant, or other expression that the compiler can evaluate without executing your program. It must be of an ordinal type compatible with selectorExpression. Thus 7, True, 4 + 5 * 3, 'A', and Integer('A') can all be used as caseLists, but variables and most function calls cannot. (A few built-in functions like Hi and Lo can occur in a caseList. See Constant expressions.)
A subrange having the form First..Last, where First and Last both satisfy the criterion above and
First is less than or equal to Last.
A list having the form item1, ..., itemn, where each item satisfies one of the criteria above.