[Lazarus] errors: Upper bound of case range is less than lower bound and duplicate case label

Sven Barth pascaldragon at googlemail.com
Mon Jan 21 10:00:32 CET 2013


Am 21.01.2013 04:54, schrieb Alexander Klenin:
> On Mon, Jan 21, 2013 at 4:43 AM, Sven Barth <pascaldragon at googlemail.com> wrote:
>>>      case gradeSelected of
>>>           '12'..'12': tuitionFee := '14500.00';
>>
>>             ^       ^   This should be easy to spot...
> No, the error is in the line below.
>
>>>           '8'..'11' : tuitionFee := '13500.00';
> Note that strings are not numbers, so '8' > '11'.
> Also, '1' < '11' < '7' < '8', so case branch labels intersect, which
> is the reason for the second error.
>
Right... I forgot that this is a case of string -.-

Regards,
Sven




More information about the Lazarus mailing list