Delphi Procedure Snippets


Here's a simple trick to execute a Delphi object's method by name:

A short and simple code snippet using voice output with Delphi

25 January, 2012   

Delphi Code example how to Cut, Copy and Paste

08 May, 2012   

Here shown an example for how to clone a Delphi Form

15 June, 2013   

Example shows here How to Clone a Delphi Form. Note: when you create a new clone from an existing form, the clone's OnCreate will not execute.

If you want to react on user maximizing or minimizing a Delphi form, use the code.

As the most important building block of any Delphi application, the TForm object is most of the times used as is. Delphi's TForm object provides enough properties and events to help you do (and control) whatever needed with it. Sometimes you'll find out that a few events or properties are missing... Try creating a simple form application. Now...

Delphi code example for Hide minimized MDI child windows

In Delphi, procedural types (method pointers) allow you to treat procedures and functions as values that can be assigned to variables or passed to other procedures and functions. Here's how to call a function (or procedure) as a parameter of another function (or procedure) : Declare the function (or procedure) that will be used as a...

08 May, 2012   

To tell if the mouse is over Delphi Form

12 April, 2012   

Delphi code example - force the input in a TEdit

Here are the procedure example to create table. you can call this procedure by command like : call myProc();

Note that you must include the unit ExtActns in the uses clause.

By default, Delphi gets its date/time, currency and numeric format from Control Panel's International settings. We can set the constants defined in Delphi, like DecimalSeparator, ShortDateFormat and others like in the code below. To a complete list of these variables, look at Currency and date/time formatting variables in Delphi Help.

02 December, 2012   

Delphi code example to extract a resource to file

Here are the example to create temporary table in a procedure .

31 December, 2011   

How to create a procedure for date calculation

You can define parameters with three types of parameters. 1. IN - The parameter can be referenced by the procedure or function. The value of the parameter can not be overwritten by the procedure or function. 2. OUT - The parameter can not be referenced by the procedure or function, but the value of the parameter can be overwritten by the...

28 March, 2011   

When you are writing dynamic link libraries and need to control the loading and unloading of a DLL, or if you want to initialize your DLL when it is loaded, you can have a function called DllMain do your initialization. Windows calls the DllMain function of a DLL in four instances: 1) When a process attaches the DLL 2) When a thread attaches...

24 August, 2011   

When you are writing dynamic link libraries and need to control the loading and unloading of a DLL, or if you want to initialize your DLL when it is loaded, you can have a function called DllMain do your initialization. Windows calls the DllMain function of a DLL in four instances: 1) When a process attaches the DLL 2) When a thread attaches...