Data types are types of data e.g.
text data. For those of you who are familiar with Databases, a data
type is like a field type. If you want to store any type of data
then you need to tell Delphi what data type you need.
These are some of the data types
(most used) you can use in Delphi:
Integer - Whole number e.g. 5.
Extended - Decimal number e.g. 5.5.
Char - One character e.g. 'A'.
String - A string of characters e.g. 'Delphi'.
PChar - A string for use with Win API (Applications Programming
"Object Pascal is a high-level,
compiled, strongly typed language that supports structured and
object-oriented design. Its benefits include easy-to-read code,
quick compilation, and the use of multiple unit files for modular
Object Pascal has special features that support Delphi's component
framework and RAD environment. For the most part, descriptions and
examples in this language reference assume that you are using
Object Pascal to develop Delphi applications.
Most Delphi developers write and
compile their code in Delphi's integrated development environment
(IDE). Delphi handles many details of setting up projects and
source files, such as maintenance of dependency information among
units. Delphi also places constraints on program organization that
are not, strictly speaking, part of the Object Pascal language
specification. For example, Delphi enforces certain file- and
program-naming conventions that you can avoid if you write your
programs outside of the IDE and compile them from the command
These Help topics generally assume
that you are working in Delphi's IDE and that you are building
applications that use the Visual Component Library (VCL).
Occasionally, however, Delphi-specific rules are distinguished from
rules that apply to all Object Pascal programming." -Delphi
Object Pascal is the language that
Delphi uses. These are the basics rules of Object
Strings are always surrounded with a
single-quote (') e.g. 'Delphi',
Each statement ends with a semi-colon (;),
If you will place a ';' directly
before an ELSE in an IF-ELSE statement.
The reason for this is that the ';' is treated as a statement
separator, not a statement terminator - IF-ELSE is one statement, a
';' cannot appear in the middle (unless you use compound
Object Pascal is not a
case-sensitive language, so the command ShowMessage for example
could be written in any case e.g. ShowMessage, showmessage,
SHOWMESSAGE, sHOwMessAge or any other case.