[fpc-pascal] String type compatibility

Marco van de Voort marcov at stack.nl
Wed Apr 3 10:46:36 CEST 2013

In our previous episode, Xiangrong Fang said:
> worksheet.lpr(9,42) Error: Incompatible types: got "TWorksheet.ShortString"
> expected "ShortString"
> I wonder who defined "TWorksheet.ShortString"? Why string[5] is not
> compatible with ShortString?

Shortstring, is an alias for shortstring[255] the maximum size. Use getters
and setters if you want to make this work.

More information about the fpc-pascal mailing list