Crash Course Delphi

You can download all of the lessons and their associated source code files, if you are a member of the DelphiLand Club.

Lesson 2: Foot2Meter simplified

In this lesson we'll create a simplified version of Foot2Meter, the application that was introduced in lesson 1.

For now, the accent will not be on what the program does, but rather on how to start a project, how to save the files, add components, and so on. But very soon, we'll continue in a higher gear.

Lesson 3: properties and events

Time to bring some life into our Delphi project.
Let's change the properties of some of the components: their caption, color, size, font, and so on. And let's add just a little bit of code. Finally, I hear you sigh... isn't that all is programming about...?

Lesson 4: Let's code !

Our Foot-To-Meter Convertor still doesn't do anything useful. In this lesson, we'll add some real code to the event handlers.

Lesson 5: Foot2Meter with RadioButtons

In this version of Foot2Meter, we'll add RadioButtons.
We'll also introduce subroutines, which constitute the power of every real programming language.

Lesson 6: Making decisions: If... Then... Else

To make decisions, a program has to determine wether a condition is TRUE or FALSE. This is done in a conditional statement, where the program flow splits up in two or more "branches".
In this lesson, we talk about the IF statement.

Lesson 7: Error handling

In the final version of Foot2Meter we add some whistles and bells. And we 'll handle the errors, in case some invalid value is entered.
In lesson 7, we introduce the Case statement, that replaces a number of nested if...then...else... statements.

Lesson 8: Foot2Meter completed

By making our Foot2Meter program look at Windows' decimal separator, we "internationalize" it, so the user won't get an error in typing the wrong decimal separator. If necessary, a comma will be converted to a point, and vice versa.
And last but not least, we add a menu. Kind of kinky, adding the menu right at the end ;-)

Lesson 9: Units Convertor

Let's make some exercices. In lesson 9, you make a general Units Convertor. This application should convert length units (cm, meter, inch,...), volumes (liter, gallon,...) or whatever you want it to convert.

Unit Convertor

We give you a template project in file unicoen1.zip, where you have to fill in most of the coding. Afterwards, you can compare with the solution contained in unicoen2.zip.
Next, we'll discuss some ways to make the source code more compact and "structured". The source code for this part of the lesson is available as unicoen3.zip


Lesson 10: Units Convertor revisited

In lesson 10 we create an extended version of the Units Convertor, using a TabControl.

Adding a TabControl


Lesson 11: Acron

In this lesson we'll create a simplified version of Acron, a program that shows a searchable list of acronyms.
In this first version, we'll show you how far you can go without adding any programming code: we'll show acronyms and their explanations in a ListBox.

Lesson 12: Acron loads strings from a file

Acron learns how to load its items from a textfile ;-)

We also introduce a better solution for aligning the two columns in the listbox: we set tabulator stops, "tabs".


You can freely view lesson1 and download the associated source code files.

Members of the DelphiLand Club can also download the full version of the other lessons, including all fully commented source code files.

Copyright 1999-2017
DelphiLand