avatar

Andres Jaimes

Switch from Debug to Release build options in Delphi

Unlike Microsoft’s Visual Studio, the option to switch from Debug to Release in Delphi is kind of hidden. However, it is very easy to use. Go to the Project menu and select Configuration Manager Now select your project, Choose a new configuration and Press the “play” button.  The following picture shows you how the Configuration Manager looks: By default, the difference between the Debug and the Release options include:

Working with dynamic arrays in Delphi

One advantage of Delphi’s dynamic arrays is that they are automatically freed once they go out of scope. That simplifies memory management and gives you more flexibility on your applications. You can declare a dynamic array like this: Customers: array of string;  Before adding an element, you have to call the SetLength function to specify the number of elements you are going to use (3 in this case): SetLength(Customers, 3);  Now you can go ahead adding values:

Tips to help you deal with Delphi Threads

Multithreading is one of those operating systems feaures that make your programs work in a more efficient way and give your users a better interactive interface. However they are not used by all developers. In this article I will focus on some important points you must have in mind when using threads on Delphi.  How to create them There are two simple steps to accomplish it: Create a new class that inherits from TThread and Override the Execute method.